price calculator java source code