Java lib for parsing and evaluating simple math expressions, using fractions. This was a seminar project in a Programming class. It is not very useful, but works
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
rcalc/src/net/mightypork/calculator/Main.java

36 lines
523 B

package net.mightypork.calculator;
import java.io.File;
/**
* Application main class
*
* @author Ondrej Hruska
*/
public class Main {
/**
* Program entry point
*
* @param args command line arguemnts
*/
public static void main(String[] args) {
if (args.length == 0 || (args.length == 1 && args[0].equals("-i"))) {
Runnable task = new CalculatorInteractive();
task.run();
} else if (args.length == 1) {
Runnable task = new CalculatorBatch(new File(args[0]));
task.run();
}
}
}