compiled and works through command line