Skip to content

Commit bcda634

Browse files
authored
Create Does s Contain t
1 parent 93f0461 commit bcda634

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/*
2+
Given two string s and t, write a function to check if s contains all characters of t (in the same order as they are in string t). Return true or false. Do it recursively.
3+
E.g. : s = “abchjsgsuohhdhyrikkknddg” contains all characters of t=”coding” in the same order. So function will return true.
4+
5+
Input Format :
6+
Line 1 : String s
7+
Line 2 : String t
8+
9+
Output Format :
10+
true or false
11+
12+
Sample Input 1 :
13+
abchjsgsuohhdhyrikkknddg
14+
coding
15+
Sample Output 1 :
16+
true
17+
18+
Sample Input 2 :
19+
abcde
20+
aeb
21+
Sample Output 2 :
22+
false
23+
*/
24+

0 commit comments

Comments
 (0)