Cod sursa(job #2682801)

Utilizator tomaionutIDorando tomaionut Data 9 decembrie 2020 18:07:36
Problema Algoritmul lui Euclid Scor 100
Compilator cpp-64 Status done
Runda Arhiva educationala Marime 0.27 kb
#include <bits/stdc++.h>

using namespace std;

ifstream fin("euclid2.in");
ofstream fout("euclid2.out");

int main()
{
    int a,b,n;
    fin >> n;
    while (n--)
    {
        fin >> a >> b;
        fout << __gcd(a,b) << "\n";
    }




    return 0;
}