#include <iostream>

int main()
{
    int a, b, c, max;
    scanf_s("%d %d", &b, &c);
    max = b;
    if (c > max) {
        max=c;
    }
    a=256-max;
    if (a > 0) {
        printf("%d", a);
    }
    else {
        printf("0");
    }
}