How can I improve (reduce the writing) for this if-else block to run a method based on an option entered? I\'ve tried looking at SO and various other areas for solutions but