public class Funcs extends java.lang.Math {
public int add(int x, int y) {
return x + y;
}
public int sub(int x, int y) {
return x - y;
}
public static void main(String[] a) {
Funcs f = new Funcs();
System.out.println("" + f.add(1, 2));
}
}
Login in to like
Login in to comment