#abc285a. A - Edge Checker 2

A - Edge Checker 2

Score : 100100 points

问题描述

判断在下图中是否存在一条直接连接编号为 aabb 的点的线段。

以上为通义千问 qwen-max 翻译,仅供参考。

Problem Statement

Determine if there is a segment that directly connects the points numbered aa and bb in the figure below.

Constraints

  • 1a<b151 \leq a \lt b \leq 15
  • aa and bb are integers.

Input

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

aa bb

Output

Print Yes if there is a segment that directly connects the points numbered aa and bb; print No otherwise.

Sample Input 1

1 2

Sample Output 1

Yes

In the figure in the Problem Statement, there is a segment that directly connects the points numbered 11 and 22, so Yes should be printed.

Sample Input 2

2 8

Sample Output 2

No

In the figure in the Problem Statement, there is no segment that directly connects the points numbered 22 and 88, so No should be printed.

Sample Input 3

14 15

Sample Output 3

No

update @ 2024/3/10 11:54:57