Problem list
Log in
#r03083 · Online Judge > GoldOJ

Starts and Ends With

Bronze III 2.0 s 1024 MB

A string $S$, a prefix candidate $A$, and a suffix candidate $B$ are given (one per line). Print whether $S$ starts with $A$, then whether $S$ ends with $B$, as Python booleans True/False.

Input

Line 1: $S$. Line 2: $A$. Line 3: $B$. All lowercase.

Output

Print the two boolean results, one per line.

Example 1

Input
programming
pro
ing
Output
True
True
Source
Online Judge > GoldOJ
Appears in
Not part of a ladder, contest or set yet.
Accepted 0 Submissions 0 Acceptance 0% Solvers 0

Discussion

Threads about this problem. Spoilers are collapsed; wrap hints in ||double bars||.

No discussion yet. Start a thread if something here needs explaining.

Recent submissions Open with filters
Code