Created
July 26, 2017 19:47
-
-
Save MohamedTaha98/b6350bce76e062b17d37319aefa1c5ce to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
int main() | |
{ | |
int n, mishka = 0, chris = 0; | |
cin >> n; | |
int ar[2]; | |
for (int rnds = 0; rnds < n; rnds++) | |
{ | |
cin >> ar[0] >> ar[1]; | |
if (ar[0] > ar[1]) | |
mishka++; | |
else if (ar[1] > ar[0]) | |
chris++; | |
} | |
if (mishka > chris) | |
cout << "Mishka"; | |
else if (chris > mishka) | |
cout << "Chris"; | |
else | |
cout << "Friendship is magic!^^"; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment