Answer:
1.)
def two(a, b) :
print(a+b)
print(a*b)
2.)
a = int(input('enter an integer values '))
b = int(input('Enter another integer value' ))
print(a+b)
print(a*b)
3.)
Take side of a square from user and print area and perimeter of it.
def square(a):
area = a**2
perimeter = 4*a
print(area, perimeter)
Explanation:
Code written in python :
The first function named two, takes to arguments a and b ;
The sum of integers a and b is taken and displayed using ; print(a+b)
The product of integers a and b is taken and displayed using ; print(a*b)
2.)
User can enter an input and converted to an integer value using the command ;
int(input()) ; the sum and product of these values are displayed using :
print(a*b) and print(a+b)
The Area and perimeter of a square requires the side length, which is taken as the argument a in the square function defined.
Area of square = a² = a**2
Perimeter = 4 * a
Answer:
You have to log in to your google account. BRAINLIEST PLEASE
Explanation:
Answer:
a. values
Explanation:
The values() method returns an array of all values of an enumeration. This method is defined automatically by the java compiler for the enum data type.
For example:
enum Traffic_Signal {RED,YELLOW,GREEN};
for(Traffic_Signal t : Traffic_Signal.values()){
System.out.println(t);
}
This code segment will print out all the valid values in the Traffic_Signal enumeration.