Question: Write in C program only. Question 2: Coordinate Converter (SUBMIT AS ONE file. Both a and b will be in the same file) Suppose you

 Write in C program only. Question 2: Coordinate Converter (SUBMIT AS

Write in C program only. Question 2: Coordinate Converter (SUBMIT AS ONE file. Both a and b will be in the same file) Suppose you are willing to design a coordinate-oriented program. For that, you need to develop a coordinate converter. Here is a sample image of the coordinate system for your convenience: II I 03 21 . x-axis III 2 IV a) Write a program that will scan four values, x, and y, current_coordinate, target_coordinate, and convert x and y into the desired coordinate (using if-else). For example, if x=7, y = 9, current_coordinate=1, target_coordinate = 4, your program will print: "New value of x and y in the target coordinate is (7.-9). b) solve the same problem (a) using "switch-case." Carefully design the "switch variable. in a single C file. After you complete the if-else part, move to the switch case part right away (before return 0). If possible, before starting switch case, write a comment like : main() { *write your part a code here // End of Part a //Part b starts here **Write your part b code here* return 0

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!