0w1

LHPC 2016 pA. 摺紙 ( Ad hoc )

因為沒有題目沒有名字,所以我決定給他亂取XDD
f:id:h0rnet:20160820211412p:plain
f:id:h0rnet:20160820211329p:plain
幸好 double 沒出問題。

void solve(){
    double a, b; cin >> a >> b;
    int ans = 0;
    while( a > 1 ) ++ans, a /= 2;
    while( b > 1 ) ++ans, b /= 2;
    cout << ans << endl;
}