Question
Problem One - search for a section Creat a java class that has a 2D array of type String. It should have three columns and
Problem One - search for a section
Creat a java class that has a 2D array of type String. It should have three columns and three rows. The array should have in column 0, the values: Alexandria, Annandale, Loudoun.
In column one the values should be: 001A, 004B, 007C. In column two the values should be 002A, 005B, 008C and in column thee the values should be 003A, 006B, 009C.
Ask the user what campus they want to search. Return all three section numbers for that campus to the user. No need to loop.
Layout of data
Alexandria 001A 002A 003A
Annandale 004B 005B 006B
Loudoun007C 008C 009C
Problem two - difference
Creat a class that asks the user for two integers. Calculate the difference of the two numbers. If the first number is larger than the second number, output to the user that they have lost the difference, include the difference value. If the second number is larger than the first, then output to the user that they have gained the difference. For example: if the user entered 12 and 8 you would display "You have lost the difference of 4".
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started