answersLogoWhite

0

There's not enough information to fully answer the question. However, when dealing with ages, you're either looking for those above or below a certain age, or determining which range of ages an object/person belongs.

The following snippet determines if an object represents a minor or a person of working age. Those who have reached retirement age aren't necessarily retired.

std::cout<<object.name<<' ';

if(object.age<16)

std::cout<<"is a minor."<<std::endl;

else if((object.age>60 && object.sex==female) object.age>65)

std::cout<<"is probably retired."<<std::endl;

else

std::cout<<"is of working age."<<std::endl;

User Avatar

Wiki User

11y ago

What else can I help you with?

Related Questions

What is the deffernce of the switch statement and the if statement in c plus plus?

If statement is single selection statement,whereas the switch statement is multiple selective.


Which statement is not frequently used in C plus plus?

The goto statement.


Enumerate the types of selection constructs in c plus plus?

Selection constructs in C++if...elseswitch/caseconditional ternary operator (?:)


What are the three selection structures available in C plus plus?

if while switch


Basic control structure available in c plus plus?

The basic control structure in C++ is the if statement.


A c plus plus statement that invokes a function is known as?

...a function call.


Which statement in C plus plus is used to implement a decision structure in its simplest form-that of choosing between two alternatives?

if (condition) statement else statement;


What is the function of visual c plus plus switch condition?

The switch / case statement.


What is the character used at the end of executable statements in C plus plus?

The semi-colon converts a C++ expression into a statement.


How can write the name in c plus plus language without using cout statement?

I believe, you can use C-function - printf().


How can you print your name in c or c plus plus with out using semi column?

You can not print your name in C without a semi colon because according to the rules of C every statement should end with a semi colon.In fact without the semi colon it fails to be a valid C statement.


Can you write plus at end of c statement?

No. That would be a syntax error. Only a right semicolon (;) can go at the end of a statement.