Word Pattern

easy
1. You are given two strings S1 and S2. S1 represents a word of length N and S2 represents N space-separated words.
2. You have to find if the words in S2 follow the exact order as characters in S1.

Note -> Every string consists of lower-case English letters only.

Input Format

Two strings S1 and S2

Output Format

true/false

Constraints

1 <= length of strings <= 1000

Example

Input
abab
pep coding pep coding
Output
true
Previous
Isomorphic Strings
Next
Longest Subarray With Sum Divisible By K

Related Questions