Question: You must write a program that take as in input, a String containing the information for a course. This course information will always be a
You must write a program that take as in input, a String containing the information for a course. This course information will always be a String formatted like this:
Here is an example:
CSE Principles of Programming
Note that the four pieces of information in this String are each separated by a single space character.
You can safely assume for this assignment that the input to your program will always follow this format.
Your program must collect and store this full course information in a single String variable. You should use the Scanner nextLine method to collect the input as a single String. Your program must then extract the four pieces of information and store each in separate variables. The subject and title must be stored in String variables. The course number and section number must be stored in int variables. Finally, you program must print out the four pieces of information on separate lines, as show in the examples below.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
