Menu Close

Get number n and Compute n+nn+nnn

Program to Read a number n and Compute n+nn+nnn

Number=int(input())
Sum=0
for i in range(0,3):
  num=Number
  for j in range(0,i):
    num*=Number
  Sum=Sum+num
print(Sum)

Output:
Enter any number: 5
155

Output:
Enter any number: 10
1110

Output:
Enter any number: 55
169455

Output:
Enter any number: 66
291918

Output:
Enter any number: 100
1010100

Output:
Enter any number: 1000
1001001000

Output:
Enter any number: 3
39

Output:
Enter any number: 2
14


Scrshot


More Codes to Fcuk

Explore