Problem9937--ABC312 —— A - Chord

9937: ABC312 —— A - Chord

[Creator : ]
Time Limit : 1.000 sec  Memory Limit : 512 MiB

Description

Given a length-$3$ string $S$ consisting of uppercase English letters, print `Yes` if $S$ equals one of `ACE`, `BDF`, `CEG`, `DFA`, `EGB`, `FAC`, and `GBD`; print `No` otherwise.

Input

The input is given from Standard Input in the following format:

```
$S$
```

Output

Print `Yes` if $S$ equals one of `ACE`, `BDF`, `CEG`, `DFA`, `EGB`, `FAC`, and `GBD`; print `No` otherwise.

Constraints

-   $S$ is a length-$3$ string consisting of uppercase English letters.

Sample 1 Input

ABC

Sample 1 Output

No
When S= ABC, S does not equal any of ACE, BDF, CEG, DFA, EGB, FAC, and GBD, so No should be printed.

Sample 2 Input

FAC

Sample 2 Output

Yes

Sample 3 Input

XYX

Sample 3 Output

No

Source/Category