"Untitled" By gando (https://pastebin.com/u/gando) URL: https://pastebin.com/Fzj2qT15 Created on: Monday 5th of September 2011 09:25:00 PM CDT Retrieved on: Saturday 31 of October 2020 07:58:14 AM UTC import javax.swing.JOptionPane; public class GCFTest { public static int InputInt(String S) // taken straight from my personally written methods.java -- only put in here for the sake of completeness, it's not in the final version of my program { int x = Integer.parseInt(JOptionPane.showInputDialog(S)); return x; } public static int GCF(int Int1, int Int2) { if (Int2 == 0) { return Int1; } return GCF(Int2, Int1 % Int2); } public static void main(String[] args) { String pd = "."; int x = InputInt("Enter a positive integer."); int y = InputInt("Enter another positive integer."); int GRCF = GCF(x, y); System.out.println("The GCF of "+x+" and "+y+" is "+GRCF+pd); } }