Advertisement
msoo248

Untitled

Jul 11th, 2019
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.33 KB | None | 0 0
  1. import random
  2.  
  3. liczba =random.randrange(1,101)
  4. print(liczba)
  5. los_1 =input ('podaj liczbę z zakresu 1-100: ')
  6. for i in range(1,6):
  7.  if int(los_1) < liczba:
  8.    print ('więcej')
  9.    los_1 =input ('podaj liczbę: ')
  10.  elif int(los_1) > liczba:
  11.    print ('mniej')
  12.    los_1 =input ('podaj liczbę: ')
  13.  else:
  14.    print ("trafiłeś")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement