File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+
2+ #include < iostream>
3+ #include < string>
4+ #include < vector>
5+ using namespace std ;
6+
7+ int main () {
8+ int a_score=0 , b_score=0 ;
9+ int a[3 ] , b[3 ];
10+ cout << " ALIX turn : " << endl;
11+ for (int i=0 ; i<3 ; i++){
12+
13+ cin >> a[i];
14+ cout << a[i]<< endl;
15+ }
16+ cout << " BOUB turn :" << endl;
17+ for (int j=0 ; j<3 ; j++){
18+ if ( j<=100 ){
19+ cin >> b[j];
20+ cout << b[j] << endl;
21+ }
22+ else {
23+ cout << " the max is 100" << endl;
24+ }
25+ }
26+ if (a[0 ] > b[0 ]){
27+ a_score= 1 +a_score ;
28+ }
29+ else if (a[0 ] ==b[0 ]){
30+ a_score +=0 ;
31+ b_score +=0 ;
32+ }
33+ else if (a[0 ] < b[0 ]){
34+ b_score= 1 +b_score ;
35+ }
36+ // round two;
37+ if (a[1 ] > b[1 ]){
38+ a_score= 1 +a_score;
39+ }
40+ else if (a[1 ]== b[1 ]){
41+ a_score +=0 ;
42+ b_score +=0 ;
43+ }
44+ else if (a[1 ] < b[1 ]){
45+ b_score= 1 +b_score ;
46+ }
47+ if (a[2 ] > b[2 ]){
48+ a_score= 1 +a_score;
49+ }
50+ else if (a[2 ]== b[2 ]){
51+ a_score +=0 ;
52+ b_score +=0 ;
53+ }
54+ else if (a[2 ] < b[2 ]){
55+ b_score= 1 +b_score ;
56+ }
57+ cout <<" |" <<a_score << " :" ;
58+ cout << b_score<< " |" ;
59+ return 0 ;
60+ }
You can’t perform that action at this time.
0 commit comments