time limit per test: 0.25
memory limit per test: 65536
Consider N points on the plane. Each point has its special number. Points arrangement is called "awful" if for any three different points A, B, and C the sum of their special numbers is equal to the area of the triangle ABC.
You are given special numbers for all points, but not their coordinates. You have to find some awful points arrangement.
It is guarantee, that last special number and previous are equal.
The first line of input contains single integer N (3<=N<=8). Next line contains N positive integers R[i] - special numbers of points (0<R[i]<=100, R[N-1]=R[N]).
On the first line output "YES" (without quotes) if the solution exists, or "NO" (without quotes) if it does not. In case of positive answer output N lines with points coordinates: X[i] and Y[i] with four digits after the decimal point.
2 3 3
1 1 1 1
|Resource:||Petrozavodsk Summer Training Sessions 2004
|Date:||August 25, 2004
|Server time: 2017-11-20 23:47:58||Online Contester Team © 2002 - 2016. All rights reserved.|