Codeforces Round 1133 (Div. 1, Div. 2) is coming soon! Register here. ×

i_am_not_special's blog

By i_am_not_special, history, 18 months ago, In English
int n;

cin >> n;

int x;

cout << "digit" << endl;

cin >> x;

cout << "digit" << endl;

cin >> x;

vector v = {2, 3, 5, 7};

int i = 0;

int cnt = 0;

while(i < 4) {

cout << "div " << v[i] << endl;
   int x;
   cin >> x;
   cnt++;
   if(x == 0)
   { 
     if(i == 0 && cnt == 3)
     {
        break;
     }

    if(i == 0 && cnt == 4)
     {
          break;
     }

    if(i == 1 && cnt == 3)
    {
       break;
    }
     i++;
     cnt = 0;
   }

}

cout << "mul " << n << endl;
    cin >> x;
    cout <<"! " << endl;

I don't know why my solution is wrong please give me some idea why its wrong

  • Vote: I like it
  • -8
  • Vote: I do not like it

| Write comment?