-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathgeometry.java
More file actions
58 lines (56 loc) · 2.18 KB
/
geometry.java
File metadata and controls
58 lines (56 loc) · 2.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
import shapes.*;
import java.util.Scanner;
class geometry{
public static void main(String args[]){
{
int choice;
Scanner in = new Scanner(System.in);
System.out.print("\n\t~~~~~~ Welcome to Geometry World ~~~~~~");
System.out.print("\n\t\tWe have codes for Geometry shapes");
System.out.print("\n\t\tWhich shape you want?");
System.out.print("\n\n\t------------------------------------");
System.out.print("\n\t\tEnter 1 for Circle");
System.out.print("\n\t\tEnter 2 for Arc of Circle");
System.out.print("\n\t\tEnter 3 for Horizontal sine wave");
System.out.print("\n\t\tEnter 4 for Vertical sine wave");
System.out.print("\n\t\tEnter 5 for Rectangle");
System.out.print("\n\t\tEnter 6 for Cardiod");
System.out.print("\n\t\tEnter 7 for Hypocycloid");
System.out.print("\n\t\tEnter 8 for Epicycloid");
System.out.print("\n\t\tEnter 9 for Nephroid");
System.out.print("\n\t-------------------------------------\n");
choice = in.nextInt();
switch (choice)
{
case 1: circle ob1 = new circle();
ob1.geo_circle();
break;
case 2: arcOfCircle ob2 = new arcOfCircle();
ob2.geo_arcOfCircle();
break;
case 3: hori_sine ob3 = new hori_sine();
ob3.geo_hori_sine();
break;
case 4: vert_sine ob4 = new vert_sine();
ob4.geo_vert_sine();
break;
case 5: rectangle ob5 = new rectangle();
ob5.geo_rect();
break;
case 6: cardiod ob6 = new cardiod();
ob6.geo_cardiod();
break;
case 7: hypocycloid ob7 = new hypocycloid();
ob7.geo_hypocyclo();
break;
case 8: epicycloid ob8 = new epicycloid();
ob8.geo_epicyclo();
break;
case 9: nephroid ob9 = new nephroid();
ob9.geo_nephro();
break;
default: System.out.print("\nOops!!!------------Sorry, You entered wrong code--------------\n");
}
}
}
}