#include <iostream>

using namespace std;


int main()
{
	int H, R;
	cin >> H >> R;

	if (H * R == -R * R)
	{
		cout << "0" << endl;
	}
	else if (H * R >= 0)
	{
		cout << "1" << endl;
	}
	else if (H * R < 0)
	{
		cout << "-1" << endl;
	}
	

		return 0;
	
}
