a switch statement maybe cleaner