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

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: 44 y-axis II 2 I 1- -5 -3 -2 -1 0 2 3 4 5 6 X-axis - 1 -2 III IV -3 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
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
