SHARE
TWEET

3833

Dari_ Feb 19th, 2019 18 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. nums = list(map(int, input().split()))
  2. res = 0
  3. for i in range(1, len(nums)-1):
  4.     if nums[i-1] < nums[i] > nums[i+1]:
  5.         res += 1
  6. print(res)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top