Bug fixing and improvements.
Extra credit still to be implemented.