c2
This commit is contained in:
parent
0d75f30a49
commit
4744ebb565
69 changed files with 7 additions and 5 deletions
|
|
@ -1,20 +0,0 @@
|
|||
// pb_5_1_40.cpp
|
||||
// Горбацевич Андрей
|
||||
#include <iostream>
|
||||
using namespace std;
|
||||
|
||||
int gcd (int a, int b) {
|
||||
while (b) {
|
||||
a %= b;
|
||||
swap(a, b);
|
||||
}
|
||||
return a;
|
||||
}
|
||||
|
||||
|
||||
int main() {
|
||||
int a, b, c;
|
||||
cout << "a, b, c >>";
|
||||
cin >> a >> b >> c;
|
||||
cout << (gcd(gcd(a,b),c) == 1? "YES" : "NO") << endl;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue