0% found this document useful (0 votes)
27 views1 page

Looping

Uploaded by

anhhh.23itb
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views1 page

Looping

Uploaded by

anhhh.23itb
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

( * ) Cố mà làm !

Vẽ hình này nhé ! :>


*
* * *
* * * * *
* * * * * * *
* * * * * * * * *
* * * * * * * * * * *
* * * * * * * * * * * * *
* * * * * * * * * * * * * * *
* * * * * * * * * * * * * * * * *
*
* *
* *
* *
* *
* *
* *
* * * * * * * * * * * * * * *

1. Write a program to calculate the sum of first n natural number, n input


from keyboard
2. Write a program that prompts the user to input a positive integer. It
should then print the multiplication table of that number.
3. Write a program to find the factorial value of any number entered through
the keyboard.
4. Write a program to print Fibonacci series of n terms where n is input by
user :
Example: 0 1 1 2 3 5 8 13 21 .....
5. Write a program to calculate the sum of following series where n is input
by user.
Example: 1 + 1/2 + 1/3 + 1/4 + 1/5 +…………1/n
6. Write a program to print out all Armstrong numbers between 1 and 500. If
sum of cubes of each digit of the number is equal to the number itself,
then the number is called an Armstrong number.
For example, 153 = ( 1 * 1 * 1 ) + ( 5 * 5 * 5 ) + ( 3 * 3 * 3 )

You might also like