Stop show with sound  Next slide in show -- Keyboard shortcut: 'n'  2 minutes, 11 secondsLecture 3 - slide 19 : 39
Program 1
import oopcourse.util.Console;

class Gcd1{

 static int gcd(int input1, int input2){
   int stor, lille, rest;
   stor = input1;  lille = input2;
   while (lille > 0){
     rest = stor % lille;
     stor = lille;
     lille = rest;
   }
   return stor;
 }

 public static void main(String args[]){
   int i, j;
   i = Console.readInt("Indlæst det største af to positive tal");
   j = Console.readInt("Indlæst det mindst af to positive tal");
   System.out.println("GCD = " + gcd(i,j));
 }
}