The Federation has asked you to develop a program to keep track of its officers.
ID: 3551970 • Letter: T
Question
The Federation has asked you to develop a program to keep track of its officers. A sample of the kind of information for each officer is
shown below.
Name: Mr. James Tiberius Kirk
Date of Birth: March 22, 2233
Address: 23 Falling Rock,
Riverside, Iowa 52327-0021
Planet Earth
Rank: Captain
Ship: USS Enterprise
Nickname: Jim
Favorite Saying: "Bones???"
Starting Stardate: 41153.7
Martial Status: Single
Starfleet Graduation Date: June 23, 2212
Name: Mr. Leonard A. McCoy Jr.
Date of Birth: 7/8/2227
Address: 8745 South Road
Jackson, Mississippi 39201-0001
Planet Earth
Rank: Chief Medical Officer
Ship: USS Enterprise
Nickname: Bones
Favorite Saying: "He's dead Jim."
Starting Stardate: 41151.8
Marital Status: Divorced
Starfleet Graduation Date: June 21, 2210
Provide the code need to DECLARE an array of structures given the above
information. Don't write a program and don't worry about initializing
the structure based on the information above.
Be careful on how you declare the members of a structure. Grading
will be based on how the flexibility of your design (i.e., define many
structures and have structures within structures if necessary).
Explanation / Answer
struct person
{
char name[50] , date[50] ,addressfield1[50] , addressfield2[50] , addressfield3[50], rank[20], ship[50];
char nickname[50] , saying[100] , marital[50] , starfleetgraduationdate[50] ;
double startingstardate;
}
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.