Kwwiker

Untitled

Apr 11th, 2021
389
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. for i in range(n - 1):
  2.     for j in range(i + 1, n):
  3.         if cena[i]/vec[i] > cena[j]/vec[j] or cena[i]/vec[i] == cena[j]/vec[j] and vec[i] < vec[j]:
  4.             cena[i], cena[j] = cena[j], cena[i]
  5.             vec[i], vec[j] = vec[j], vec[i]
RAW Paste Data