Guest User

Untitled

a guest
Feb 15th, 2020
84
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. a, b, c, d, e = [int(i) for i in input().split()]
  2. f = input().split()
  3. if b >= e:
  4. print((a - 1) * c + e * d)
  5. print('NO')
  6. else:
  7. print((a - 1) * c + b * d)
  8. print(f[b])
RAW Paste Data