Question: Part 1: 1) Write a C program getPhoneNumber.c that accepts a phone number from the user in the form XXX-XXX-XXXX, and then displays it in

 Part 1: 1) Write a C program getPhoneNumber.c that accepts a

Part 1: 1) Write a C program getPhoneNumber.c that accepts a phone number from the user in the form XXX-XXX-XXXX, and then displays it in the form (XXX)XXX-XXXX Enter a date (XXX-XXX-XXXx): 011-123-4567 You entered (011) 123-4567 Question: Execute your getPhoneNumber.c and attach a screenshot of the output. Thern write the source code of getPhoneNumber.c in your answer sheet and upload your file getPhoneNumber.c to iCollege. 2) Suppose that we call scanf as follows: scanf ( " % f%d% f", &x, &i, &); Question: If the user enters 12.1 5.65 789 What will be the values of i, x and y after the call? (Assume that x and y are float variables and i is an int variable.) And explain why? Put your answer in the answer sheet. 3) Suppose that we call scanf as follows: scan f ("%d% f %d", &i, &, &j); If the user enters 10.2 8 6 What will be the values of i, x and j after the call? (Assume that i and j are int variables and x is a float variable.) And explain why? Put your answer in the answer sheet

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!