eolymp
bolt
Try our new interface for solving problems
Problems

startsWith endsWith

startsWith endsWith

Three lines of characters is given. Check if the second line is a prefix of the first line. Check if the third line is a suffix of the first line.

Input

Three lines, each contains no more than 100 characters.

Output

In the first line print true or false depending on whether second line is a prefix of the first one. In the second line print true or false depending on whether third line is a suffix of the first one.

Time limit 1 second
Memory limit 128 MiB
Input example #1
qwerty
qwe
ty
Output example #1
true
true
Input example #2
asdfghj
as
uj
Output example #2
true
false
Author Michael Medvedev