Toggle navigation
YouTube
Facebook
Telegram
english
english
українська
Algotester 4.3
Build 501
2024-12-30
Log In
Contact Us
College
Sponsors
Donate
Sources
PyPy
n, k = map(int, input().split()) p = [int(i) for i in input().split()] m = 0 for i in range(n - 1): if p[i + 1] != p[i] + 1: m += 1 m += 1 if m <= k: print("Yes") else: print("No")