Pentagon

AtCoder
IDabc333_b
Time2000ms
Memory256MB
Difficulty
A regular pentagon $P$ is shown in the figure below. ![image](https://img.atcoder.jp/abc333/2d0c9295b03ff6d808c1ee9125045fc8.png) Determine whether the length of the line segment connecting points $S_1$ and $S_2$ of $P$ equals the length of the line segment connecting points $T_1$ and $T_2$. ## Constraints * Each of $S_1$, $S_2$, $T_1$, and $T_2$ is one of the characters `A`, `B`, `C`, `D`, and `E`. * $S_1 \neq S_2$ * $T_1 \neq T_2$ ## Input The input is given from Standard Input in the following format: $S_1S_2$ $T_1T_2$ [samples]
Samples
Input #1
AC
EC
Output #1
Yes

The length of the line segment connecting point `A` and point `C` of $P$ equals the length of the line segment connecting point `E` and point `C`.
Input #2
DA
EA
Output #2
No

The length of the line segment connecting point `D` and point `A` of $P$ does not equal the length of the line segment connecting point `E` and point `A`.
Input #3
BD
BD
Output #3
Yes
API Response (JSON)
{
  "problem": {
    "name": "Pentagon",
    "description": {
      "content": "A regular pentagon $P$ is shown in the figure below. ![image](https://img.atcoder.jp/abc333/2d0c9295b03ff6d808c1ee9125045fc8.png) Determine whether the length of the line segment connecting points $S_",
      "description_type": "Markdown"
    },
    "platform": "AtCoder",
    "limit": {
      "time_limit": 2000,
      "memory_limit": 262144
    },
    "difficulty": "None",
    "is_remote": true,
    "is_sync": true,
    "sync_url": null,
    "sign": "abc333_b"
  },
  "statements": [
    {
      "statement_type": "Markdown",
      "content": "A regular pentagon $P$ is shown in the figure below.\n![image](https://img.atcoder.jp/abc333/2d0c9295b03ff6d808c1ee9125045fc8.png)\nDetermine whether the length of the line segment connecting points $S_...",
      "is_translate": false,
      "language": "English"
    }
  ]
}
Full JSON Raw Segments