|
| 1 | +# class Greeting: |
| 2 | +# |
| 3 | +# def sayHello(self, name = None, wish = None): |
| 4 | +# if name is not None and wish is not None: |
| 5 | +# print ('Hello' + name + wish) |
| 6 | +# elif name is not None and wish is None: |
| 7 | +# print ('Hello' + name) |
| 8 | +# else: |
| 9 | +# print ('Hello') |
| 10 | +# greet = Greeting() |
| 11 | +# # Call the method with zero, one and two parameters |
| 12 | +# greet.sayHello() |
| 13 | +# greet.sayHello('Ram') |
| 14 | +# greet.sayHello('Ram,', 'Good Morning!!!') |
| 15 | + |
| 16 | +#area of rectange, circle square |
| 17 | +# class Area: |
| 18 | +# def area(self, l=None , b=None , r=None): |
| 19 | +# if l is not None and b is not None and r is None: |
| 20 | +# print("area of rectange:",l*b) |
| 21 | +# elif l is not None and b is None and r is None: |
| 22 | +# print("area of square:",l**2) |
| 23 | +# elif l is not None and b is not None and r is not None: |
| 24 | +# print("area of circle:",3.14*r**2) |
| 25 | +# print("area of square:", l ** 2) |
| 26 | +# print("area of rectangle:", l*b) |
| 27 | +# a1=Area() |
| 28 | +# a1.area(int(input()),int(input())) |
| 29 | +# a1.area(int(input())) |
| 30 | +# a1.area(int(input()),int(input(),int(input()))) |
| 31 | + |
| 32 | + |
0 commit comments