题解 | #特工的密码#
特工的密码
https://www.nowcoder.com/practice/bcdfed09de534aea92b24c73699dba5c
import java.util.*;
public class Solution {
public boolean isSubsequence (String s, String t) {
int index=0;
for(int i=0;i<t.length();i++){
if(s.charAt(index)==t.charAt(i)){
index++;
}
if(index==s.length()){
return true;
}
}
return false;
}
}
华为HUAWEI公司氛围 740人发布
