added the switch case and input menu