#abc309a. A - Nine

A - Nine

Score : 100100 points

问题描述

我们有一个如下的 3×33 \times 3 矩阵,上面写有从 1199 的整数。

已知两个整数 AABB,它们都在 1199 之间,并且满足 A<BA < B

请确定标有 AABB 的两个方格是否在水平方向上相邻。

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

Problem Statement

We have the following 3×33 \times 3 board with integers from 11 through 99 written on it.

You are given two integers AA and BB between 11 and 99, where A<BA < B.

Determine if the two squares with AA and BB written on them are adjacent horizontally.

Constraints

  • 1A<B91 \le A < B \le 9
  • AA and BB are integers.

Input

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

AA BB

Output

Print Yes if the two squares with AA and BB written on them are adjacent horizontally, and No otherwise.

Sample Input 1

7 8

Sample Output 1

Yes

The two squares with 77 and 88 written on them are adjacent horizontally, so print Yes.

Sample Input 2

1 9

Sample Output 2

No

Sample Input 3

3 4

Sample Output 3

No

update @ 2024/3/10 08:45:39