Create the logic for a program that continuously prompts the user for two numeric values that represent the sides of a rectangle. Include two overloaded methods that compute a rectangle’s area. One method takes two numeric parameters and calculates the area by multiplying the parameters. Th e other takes a single numeric parameter, which is squared to • If both numbers entered are greater than 0, call the method version that accepts two parameters and pass it both values. • If one of the values entered is 0 but the other is not, call the version of the method that accepts just one parameter and pass it the nonzero value. • If both the entered values are 0, display an error message. • If both numbers entered are greater than 0, call the method version that accepts two parameters and pass it both values. • If one of the values entered is 0 but the other is not, call the version of the method that accepts just one parameter and pass it the nonzero value. • If both the entered values are 0, display an error message.
12. Create the logic for a program that prompts a user for three numbers and stores them in an array. Pass the array to a method that reverses the order of the numbers. Display the reversed numbers in the main program.