#include using namespace std; typedef long long ll; int main(){ ll a, b, c, d; cin >> a >> b >> c; c = c * 3600; a = a * 60; d = a - b; cout << ( ( (c+d-1)/d < 0 ) ? -1 : (c+d-1)/d ) << endl; return 0; }