Prefix?

AtCoder
IDabc268_b
Time2000ms
Memory256MB
Difficulty
You are given two strings $S$ and $T$ consisting of lowercase English letters. Determine if $S$ is a prefix of $T$. What is a prefix? A prefix of a string $T_1T_2\ldots T_N$ of length $N$ is a string expressed as the first $i$ characters of $T$, $T_1T_2\ldots T_i$, where $i$ is an integer such that $0 \leq i \leq N$. For example, when $T = $ abc, there are four prefixes of $T$: an empty string, a, ab, and abc. ## Constraints * $S$ and $T$ are strings of lengths between $1$ and $100$ (inclusive) consisting of lowercase English letters. ## Input Input is given from Standard Input in the following format: $S$ $T$ [samples]
Samples
Input #1
atco
atcoder
Output #1
Yes

`atco` is a prefix of `atcoder`. Thus, `Yes` should be printed.
Input #2
code
atcoder
Output #2
No

`code` is not a prefix of `atcoder`. Thus, `No` should be printed.
Input #3
abc
abc
Output #3
Yes

Note that a string is also a prefix of itself.
Input #4
aaaa
aa
Output #4
No
API Response (JSON)
{
  "problem": {
    "name": "Prefix?",
    "description": {
      "content": "You are given two strings $S$ and $T$ consisting of lowercase English letters. Determine if $S$ is a prefix of $T$. What is a prefix? A prefix of a string $T_1T_2\\ldots T_N$ of length $N$ is a string ",
      "description_type": "Markdown"
    },
    "platform": "AtCoder",
    "limit": {
      "time_limit": 2000,
      "memory_limit": 262144
    },
    "difficulty": "None",
    "is_remote": true,
    "is_sync": true,
    "sync_url": null,
    "sign": "abc268_b"
  },
  "statements": [
    {
      "statement_type": "Markdown",
      "content": "You are given two strings $S$ and $T$ consisting of lowercase English letters. Determine if $S$ is a prefix of $T$.\nWhat is a prefix? A prefix of a string $T_1T_2\\ldots T_N$ of length $N$ is a string ...",
      "is_translate": false,
      "language": "English"
    }
  ]
}
Full JSON Raw Segments