You are on page 1of 1

Task1: Create a method called Print to show the following sentence on the output screen.

“Welcome to ITM dept.”

Task2: Create a method called Sum to return the sum of two numbers.

Task3: Create a method called Fabon to display the n number Fibonacci sequence. The
Fibonacci Sequence: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55…

Task4: Write a method to return the minimum number among three integer numbers.

(H.W.: solve this task using ternary operator).

Task5: Write a method to display the following sequence. The Sequence: 20, 12, 4, -4, -12, -20.

Task6: Write a method to return the result of raising an integer number to another (ex.:
72=49).

Task7: Create a method to input a string and count the number of spaces in the string.

Task8: Write a method to return the sum of single array elements.

Task9: Write a method (Function) to return the area and perimeter of circle. (area=r*r*3.14
and perimeter=2*r*3.14).

You might also like