Basic java code