I am writing a program that asks a user for their birthdate in three separate steps: month, day and year, but where the month is given as a word, like "April". I want my program to return the date in the form "mm/dd/yyyy". This means the day will have to be output as a two digit numeral, where day 9 would be entered as 09
here is what I have created so far. I am not sure how to implement my "Input" functions into my "Switch" function.
Clear[month, day, year, monthSwitch, a];
month = Input["What is your birthday month? Such as " April ""];
day = Input[ "What day is your birthday? If the day number falls in between 1-9, please enter 0 number, such as 09 "];
year = Input[ "What year were you born in? Please enter the 4 digit year, such as 1994"]
Clear[a, month, color];
color[monthSwitch_] := (
a = monthSwitch;
Switch[a,
January, "01",
February, "02",
March, "03",
April, "04",
May, "05",
June, "06",
July, "07",
August, "08",
September, "09",
October, "10",
November, "11",
December, "12",
_, monthSwitch]);
I am not sure know how I should go about the rest of this..