Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

a. Declare a structure date that includes the integer members month, day, and ye

ID: 3827912 • Letter: A

Question

a. Declare a structure date that includes the integer members month, day, and year. b. Declare a structure customer_info that includes a character array customer_id with 10 elements, a character acct_type a character array name with 20 elements, a double element balance, and pay_date of type date. c. Declare a structure variable customer of type customer_info and initializes it to 11, 15, 2016, 'E' "A567X", 586.50, "John Smith" keep track of its paintings and photographs. It keeps at most walls. Each one is described by the following information: watercolor, pastel, acrylic, print, color photo, black and white photo} green, blue, north, south, entry, balcony}

Explanation / Answer

Solution:

b)

c)

cusomer.customer_id= "A567X"; // dot(.) operator is used to access the variable in side structure

customer.acc_type= "E";

customer.name= "John Smith"

customer.balance= 586.50

customer.pay_date.month= 11 /* Here double dot (.) is used one is to access pay_dat and another is for accessing month, day and year */

customer.pay_date.day= 15

customer.pay_date.year= 2016

I hope this helps. Don't forget to give a thumbs up if you like this.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote