import math ng_flg = 1 a = input() b = input() # 入力チェック if a.find("0") != 0 and b.find("0") != 0: if a.isdigit() and b.isdigit(): n = int(a) m = int(b) if 0<=n<=12345 and 0<=m<=12345: ng_flg = 0 print(n+m) if ng_flg == 1: print("NG")