Question: write a program named ConvertDate that converts a date entered by the user into another form. The users inout will have the form month day,

write a program named ConvertDate that converts a date entered by the user into another form. The users inout will have the form month day, year. The month will be one of the words January, February.. the letters in the month maybe lowercase, uppercase, or any mixture of the two. the day is one or two digit number. the year is any number of digits. there maybe any number of spaces (1) before the month, (2) between the month and the day (3) between the day and the year, and (4) after the year. You may assume that there is at least one space between the mont and day and between the day and year. You may also assume that there is a comma after the day. The converted date must have the form

day month year

with one space between the day and month and between the month and year. the first letter of the month must be uppercase and the remaining letters must be lowercase. the following examples show what the the screen"

enter date to be converted: april 28, 2003

converted date: 28 april 2003

Hint: use the index Od and lastIndexOf methods to locate the month, day and year within the string entered by the user, and then use the substring method to extract them.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!