Triangle Quest - Python math solution

Author: Al-mamun Sarkar Date: 2020-03-26 09:09:59

Triangle Quest - Python math solution. The following shows how to solve the HackerRank Triangle Quest Python Math problem.

Code:

for i in range(1,int(input())): 
    print( ((pow(10, i)-1)//9) * i )

 

Test Input:

5

Test Output:

1
22
333
4444