x=8 >> Assuming user inputs a integer =8
for i in Range_GENERATED(starting from 8,decrementing till 0 ):
print( ((str(x)) + ' ')*i ) >> Print the pattern i times,
>> where i is calualted from above range
>>computation
Looks like a assignment , so giving hints below& pseudo above .
Find out how to print an expression n-times.
Checkout how to loop in python.
Range() is good place to increment/decrement the counters.