#include using namespace std; typedef long long ll; int main(){ ll n,k; cin>>n>>k; int diff=0,same=0; vector a(n); for(int i=0;i>a[i]; if(a[i]==i+1) same++; else diff++; } k-=max(diff-1,0); if(k<0) cout<<"NO"<0) cout<<"YES"<