i_am_not_special's blog

By i_am_not_special, history, 11 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

»
11 months ago, hide # |
 
Vote: I like it 0 Vote: I do not like it

Auto comment: topic has been updated by i_am_not_special (previous revision, new revision, compare).