https://acs.jxnu.edu.cn/problem/CF12A
描述:
There is a very secret base in Potatoland where potato mash is made according to a special recipe. The neighbours from Porridgia decided to seize this recipe and to sell it to Pilauland. For this mission they have been preparing special agent Pearlo for many years. When, finally, Pearlo learned all secrets of espionage, he penetrated into the Potatoland territory and reached the secret base.
在Potatoland有一个秘密基地,那里的土豆泥是根据一个特殊配方制作的。来自Porridgia的领居决定得到这个配方把它卖给Pilauland。多年来,他们一直在为这次任务做准备。最后,Pealo得知了所有的间谍活动秘密,他潜入了Potatoland并且到达了秘密基地
Now he is standing at the entrance, but to get inside he need to pass combination lock. Minute ago one of the workers entered the password on the terminal and opened the door. The terminal is a square digital keyboard 3 × 3 with digits from 1 to 9.
现在他站在入口,但是为了进入他必须穿过联合封锁。一分钟前一分钟前,一名工人在终端上输入密码并打开了门。终端是一个方形数字键盘3 × 3,数字从1到9。
Pearlo knows that the password consists from distinct digits and is probably symmetric with respect to the central button of the terminal. He has heat sensor which allowed him to detect the digits which the worker pressed. Now he wants to check whether the password entered by the worker is symmetric with respect to the central button of the terminal. This fact can Help Pearlo to reduce the number of different possible password combinations.
Pearlo知道密码由不同的数字组成,可能与终端的中央按钮对称。他有一个热传感器,可以让他找到工作人员输入的数字。这个条件能帮助Pearlo减少密码的组合
输入:
Input contains the matrix of three rows of three symbols each. Symbol «X» means that the corresponding button was pressed, and «.» means that is was not pressed. The matrix may contain no «X», also it may contain no «.».
输入包含三个矩阵,每行三个符号。符号«X»表示按下了相应的按钮,«。»表示未按下该按钮。矩阵可能不包含«X»,也可能不包含«。».
输出:
Print YES if the password is symmetric with respect to the central button of the terminal and NO otherwise.
如果密码与终端中央按钮对称,则打印“是”,否则打印“否”。