// #define _GLIBCXX_DEBUG #include using namespace std; int N,A[201010]; int main(){ ios::sync_with_stdio(false); std::cin.tie(nullptr); cout<>N; for(int i=1;i<=N;i++)cin>>A[i]; for(int i=0;i<=N;i++){ if(abs(A[i]-A[i+1])>1){ cout<<"No"<