Skip to content

Instantly share code, notes, and snippets.

@h3yon
Created May 31, 2020 23:16
Show Gist options
  • Save h3yon/8bda4060cb4519e56747a620c28e0190 to your computer and use it in GitHub Desktop.
Save h3yon/8bda4060cb4519e56747a620c28e0190 to your computer and use it in GitHub Desktop.
#include "readInput.h"
#include <iostream>
using namespace std;
int main() {
int input1, input2;
int big, small;
input1 = getNotZero();
input2 = getNotZero();
if (input1 > input2) {
big = input1;
small = input2;
}
else {
big = input2;
small = input1;
}
cout << big % small;
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment