#include //ios::sync_with_stdio(false); //cin.tie(0); using namespace std; typedef long long ll; typedef pair pii; typedef pair ppii; typedef pair pipi; typedef pair pll; typedef pair plpl; typedef tuple tl; ll mod=1000000007; ll mod2=998244353; ll inf=1000000000000000000; double pi=2*acos(0); #define rep(i,m,n) for(int i=m;i=m;i--) ll lmax(ll a,ll b){ if(a>p>>q>>r; ll a,b,c;cin>>a>>b>>c; ll d[3],e[3]; d[0]=p*(a-1)+1; e[0]=p*(a-1)+p; d[1]=q*(a+b-1)+1; e[1]=q*(a+b-1)+q; d[2]=r*(a+b+c-1)+1; e[2]=r*(a+b+c-1)+r; sort(d,d+3); sort(e,e+3); if(d[2]>e[0])cout<<-1<