# |
Author |
Problem |
Lang |
Verdict |
Time |
Memory |
Sent |
Judged |
|
146355826 |
Practice:
20pivot |
1553D
- 27
|
JavaScript
|
Accepted
|
374 ms
|
1124 KB
|
2022-02-14 16:36:23 |
2022-02-14 16:36:23 |
|
for(t=readline();t--;){
x=readline(),y=readline()
for(i=x.length-1, p=y.length-1; ~p && i>-1; i--) {
~p && x[i] == y[p] ? p-- : i--;
}
print(~p?'NO':'YES')
}
Click to see test details