#include #include using namespace std; #define SIZE 50 double prob[SIZE+3], temp[SIZE+3], lose[SIZE+3], tempLose[SIZE+3], delay[SIZE+3]; bool loseTurn[SIZE+3]; int squares[SIZE+3]; int getCmd(int index) // // read in next square command // { char ch; cin >> ch; if (ch == '0') return 0; if (ch == 'L') { loseTurn[index] = true; return 0; } int n; cin >> n; if (ch == '+') return n; else return -n; } void main() { int nCase; cin >> nCase; for(int cases=1; cases<=nCase; cases++) { int m, t, i; cin >> m >> t; for(i=0; i 0.5) cout << "Bet for. "; else if (prob[m+1] < 0.5) cout << "Bet against. "; else cout << "Push. "; if (prob[m+1] >= 0.99995) cout << "1.0000" << endl; else { cout.setf(ios::fixed,ios::floatfield); cout.precision(4); cout << prob[m+1] << endl; } } }