public class Client { public static void main (String[] args){ FunListFW adam = EmptyFW.Singleton (); FunListFW julie = new ConsFW (new Integer (5), adam); IFunAlgo derek = SumAlgo.Singleton (); IFunAlgo mike = GetNth.Singleton (); System.out.println ("Sum is " + julie.execute (derek, null)); System.out.println ("Oth element is " + julie.execute (mike, new Integer (0))); try { System.out.println ("Press Enter to quit..."); System.in.read (); } catch (Exception e){ } } }