#include <iostream>
#include <cmath>
#include <cstdlib>
using namespace std;


int main() {
	
	int A,B,C;
	const int D=0,razlika=256;
	cin>>A>>B;
	
	if((A+B)==256) cout<<D;
     else if (A>B) 
	  C==razlika-A;
	   cout<<C;
    if (B>A)
        C==razlika-B;
        cout<<C;
	
	
	return 0;
}