AM_I_Learning's blog

By AM_I_Learning, history, 5 years ago, In English

solution is that check if there is an entry in the array from i=2 to i=n-1; such that a[i]<a[i-1]&&a[i]<a[i+1]. If there is such a value ans is NO else answer is always "YES". This is an easy way to solve that problem.... OK................

  • Vote: I like it
  • -11
  • Vote: I do not like it

»
5 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Auto comment: topic has been updated by AM_I_Learning (previous revision, new revision, compare).