#Lutece1847. 算数低手

算数低手

Migrated from Lutece 1847 算数低手

All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.

Description

定义一种新的运算'*'.

'*'运算满足对于任意的两个数x,yx, y, 都有:

a

'*'运算也满足结合率.


定义一种'字句'ww, 满足后面关系:

w=a(w)w = a * (w')w=(w)aw = (w') * aw=abw = a * b

(其中的aabb可以为任意变量('a' - 'z'))

举例: w=d(((ab)a)c)w = d*(((a*b)*a)*c)


给出一个由加法和'字句'组成的等式, 问等式是否是恒成立的.

等式的形式如下:

b

Input

一行, 表示题目中给出的等式, 等式中的变量只会是'a'-'z'的26个小写字母

Output

一行, 等式恒成立输出'True'(不要引号), 否则输出'False'(不要引号)'

Samples

(a * b) * b = b * (b * a)
True

Resources

每周一题 div2