Comments and ordering of code
Main complete. Added algorithm option