Solving Linear Equations
- Consider a system of linear equations of two variables x and y.
a1x+b1y = c1
a2x+b2y = c2
- Write a program to input a1, b1, c1, a2, b2, c2 and solve the value of x and y.
- In this homework, you may assume that the given coefficients will always yield an exact solution.
- The input line will consist of 6 coefficients, in the order a1, b1, c1, a2, b2, c2. These coefficients will be floating-point numbers separated from each other by one or more spaces.
The program may run as follows:
1 1 13
1 -1 1
x = 7
y = 6