fork(4) download
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int nod(int a, int b){
  6. cout<<"OK";
  7. int c=0;
  8. while(a+b!=0){
  9. if(a>b) a=a%b;else b=b%a;
  10. c=a;a=b;b=c;}
  11. return a+b;
  12. }
  13. int main()
  14. {
  15. nod(5,15);
  16. return 0;
  17. }
  18.  
Runtime error #stdin #stdout 0s 3412KB
stdin
Standard input is empty
stdout
Standard output is empty