Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

PROGRAM: 1.

Write a program to enter two numbers and print the arithmetic


operations like +,-,*/,//,** and %.

OUTPUT:

1
PROGRAM: 2. Write a program to find whether an inputed number is
perfect or not.

OUTPUT:

2
PROGRAM: 3. Write a program to check if the number is Armstrong or
not.

OUTPUT:

3
PROGRAM: 4. Write a program to find factorial of the entered number.

OUTPUT:

4
PROGRAM: 5. Write a program to enter the number of terms and to print the
Fibonacci series.

OUTPUT:

5
PROGRAM: 6. Write a program to enter the string an to check if it’s palindrome or
not using loop.

OUTPUT:

6
PROGRAM: 7. Write a program that generates series using a function
while takes first and last values of the series and then generates four
terms that are equidistant e.g., If two numbers are passed are 1 and 7
then function returns 1 3 5 7.

OUTPUT:

7
PROGRAM: 8. Write program to find the sum of the following series:
X + x^2/2 + x^3/3 + ….. + x^n/n (Input x and n both)

OUTPUT:

You might also like