Added enough functionality so the program is now marginally useable.