PCPC12A - Game
Fegla and Mamdouh are playing a new game. Each one of them stands on a point in X-Y plane. Fegla is standing on the point (X1,Y1) and Mamdouh is standing on point (X2,Y2). The aim of the game is to calculate the midpoint between them quickly, the one who calculates this point faster is the winner. Fegla is a very good mathematician and every time he calculates this point quickly and wins the game. Mamdouh is now upset of that and he decided to cheat (Don't do like him!). He decided to make a program to calculate this midpoint faster than Fegla. Your task is to help him in doing that.
The first line contains one Integer N which is the number of games between Fegla and Mamdouh. Each line contains four integers X1, Y1, X2 and Y2 as described above.
Print N lines each line contains two numbers which are the coordinates of the midpoint between Fegla and Mamdouh. It is guaranteed that the midpoint will be on a lattice point.
1 2 3 4
2 2 2 2
easy one but average for beginners..!!!
done :) .
Tutorial! Very easy!