Computers and Technology
Computers and Technology, 17.12.2020 22:00, yoyo4396

Project 15A - Math Application package: proj15A

Classes: Main, Circle, Rectangular

Using your new knowledge of methods and classes create a program with an interface. The program must allow a user to enter values and calculate: Areas, Perimeters, Surface Area, and Volumes for circular and rectangular shapes.

The program must have three classes. A main class, circle class and a rectangular class.

Submit all code one after the other as text into Canvas in the following order.

• main. class
• circle. class
• rect. class

I have it all done just need to finish this code

package math;

import java. util. Scanner;

public class Main
{

public static void main(String[] args)// main method
{
Scanner nScan = new Scanner(System. in);
DecimalFormat mf = new DeciamlFormat("0.0");
Circle cir1 = new Circle(0,0);
Rectangle rec1 = new Rectangle (0,0,0);

//variables
boolean runProg = true;
int choice =0;

while(runProg)
{
System. out. print("Math calculator 3000 ver1");
System. out. print("choose a mode. \n"
+ "1 circle mode \n"
+ "2 Rectangle mode \n"
+ "3 End program");
choice = nScan. nextInt();

if(choice==1) //circle mode
{

}

else if(choice == 2) //Rectangle Mode
{

}

else if(choice == 3) //Program Shutdown
{

}

else
{
System. out. println("You may only choose 1-3. Try again.");
}

}

nScan. close();
}

}

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 02:00, mayapril813
Consider the following function main: int main() { int alpha[20]; int beta[20]; int matrix[10][4]; . . } a. write the definition of the function inputarray that prompts the user to input 20 numbers and stores the numbers into alpha. b. write the definition of the function doublearray that initializes the elements of beta to two times the corresponding elements in alpha. make sure that you prevent the function from modifying the elements of alpha. c. write the definition of the function copyalphabeta that stores alpha into the first five rows of matrix and beta into the last five rows of matrix. make sure that you prevent the function from modifying the elements of alpha and beta. d. write the definition of the function printarray that prints any onedimensional array of type int. print 15 elements per line. e. write a c11 program that tests the function main and the functions discussed in parts a through d. (add additional functions, such as printing a two-dimensional array, as needed.)
Answers: 3
image
Computers and Technology, 24.06.2019 15:00, mbede002
Who introduced the concept of combining artificial and natural light in the studio
Answers: 1
image
Computers and Technology, 24.06.2019 21:50, carter4026
The use of phrases, fragments, and punctuation can influence the mood of a passage; keeping this in mind, how would you describe the mood of the followingpassage? "fog on the essex marshes, fog on the kentish heights, fog creeping into the cabooses of collier-brigs; fog lying out on the yards, and hovering in the riggingof great ships; fog drooping on the gunwales of barges and small boats. fog in the eyes and throats of ancient greenwich pensioners, wheezing by thefiresides of their wards; fog in the stem and bowl of the afternoon pipe of the wrathful skipper; fog cruelly pinching the toes and fingers of his shivering little'prentice boy on deck." (5 points)
Answers: 2
image
Computers and Technology, 24.06.2019 23:00, lovelifekristy
Aselect query joins tables together by their a. table names. b. primary keys. c. first entries. d. field names.
Answers: 2
Do you know the correct answer?
Project 15A - Math Application package: proj15A

Classes: Main, Circle, Rectangular

Questions in other subjects:

Konu
Mathematics, 13.10.2020 09:01
Konu
Mathematics, 13.10.2020 09:01