import random
S = random. randint(1,200000)/100
if S > 1000:
discount = round(0. 25*S,2)
elif S > 500:
discount = round(0. 1*S,2)
elif S > 100:
discount = round(0. 05*S,2)
print('nСумма покупки:',S,'грн','nСкидка:',discount,'грн','nСумма к оплате:',round(S-discount,2),'грн')