Added exisitng code that I have been working on for a month