Separated the majority of the code into the getInput and renameFiles methods. Added some javadoc comments, and fixed up a few miscellanious things.
Fixed an error where a statement was still working as if the for loop wasn't a foreach loop.