Reviewed All of Afshin's code. Cleaned up. Compile/ran.