The REAL Final Version

Comments are added.
"input.close();" is added because of the warning by Eclipse.