anonymous
  • anonymous
write a short program to find the oldest person between you and one other individual. Use a flow control statement to print the outcome of the result.
Computer Science
katieb
  • katieb
See more answers at brainly.com
At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.

Get this expert

answer on brainly

SEE EXPERT ANSWER

Get your free account and access expert answers to this
and thousands of other questions

anonymous
  • anonymous
What language do you need to use? The simplest way to do this is with an if-else statement if( /**/ ) { //print .... } else { //print .... }
anonymous
  • anonymous
I believe that it is supposed to be switch.
anonymous
  • anonymous
http://en.wikipedia.org/wiki/Control_flow -- All of the general flow control statements for most programming languages. A switch is not viable since you have two values Age1 and Age2, there's you wouldn't be able to compare both of those inside a switch, unless your programming language lets you do an evaluation inside a switch, though I don't think it's possible. Switches are for specific values on a single variable, let's say you expect age to be between 1-100 switch(Age1){ case 1: case 2: case 3: System.out.println("Toddler"); break; case 4: .... case 12: System.out.println("Kid"); break; case 13: ... case 18: System.out.println("Adolescent"); break; ...etc } Flow control for comparisons between two variables will usually be if-else

Looking for something else?

Not the answer you are looking for? Search for more explanations.