/****************************************************************************** * Compilation: javac Square.java * Execution: * * A function that implements the Function interface. * ******************************************************************************/ public class Square implements Function { public double evaluate(double x) { return x*x; } }