Code compacted a bit more. Removed hard coded messages.