?
№ | Отправитель | Задача | Язык | Вердикт | Время | Память | Отослано | Протест. | |
---|---|---|---|---|---|---|---|---|---|
196328567 |
Дорешивание: 2000032139cse |
1800E2 - 31 | Python 3 | Полное решение | 155 мс | 3052 КБ | 2023-03-07 05:41:39 | 2023-03-07 05:41:39 |
for _ in range (int(input())): n,k=map(int,input().split()) s1=input();s2=input() if n<=k: print('YES' if s1==s2 else 'NO') else: i=n-k print("YES" if sorted(s1)==sorted(s2) and s1[i:-i] ==s2[i:-i] else "NO")
?
?
?
?