#include 
#include 
using namespace std;
int main(){
	int Iball;
	int Ias;
	int Isum;

	bool Bwith;
	char Cwith;

	bool Ba;
	int Iout [256];
	int Icount = 0;
	int Icounto = 0;

	while (true){
		cin >> Iball >> Cwith >> Ias;

		if (int(Cwith) == 87)
				Isum = Iball - Ias;
			else
				Isum = Iball + Ias;

		if (int(Cwith) == 87 && Iball == 0 && Isum == 0)
			break;


		if (Isum < -200){
			Ba = false;
			Iout[Icount] = -300;
		}else{
			Ba = true;
			Iout[Icount] = Isum;
		}
		Icount++;
	}

	//Icounto = Icount;
	for(Icounto = 0; Icounto < Icount; Icounto++){
		if (Iout[Icounto] > -300){
			cout << Iout[Icounto] << endl;
		}else{
			cout << "Not allowed" << endl;
		}
	}
return 0;
}

    Source: geocities.com/twomcm/prog_code

               ( geocities.com/twomcm)