//* Problem  : D: Fractal
//* Origin   : NWERC-2009
//* Type     : Judge
//* Date     : 2010.02.19
//* Author   : alt
//* Language : C++

#include <stdio.h>
#include <math.h>
#include <string.h>
#include <stdlib.h>
#include <string>
#include <iostream>
#include <set>
#include <map>
#include <vector>
#include <algorithm>
#include "testlib.h"

using namespace std;

int main(int argc, char *argv[])
{
	registerTestlibCmd(argc, argv);

	int nt = 0;
	while (1)
	{
		++nt;
		string sans = ans.readString();
		if (sans.length() == 0 && ans.eof())
			break;
		double xj, yj;
		if (sscanf(sans.c_str(), "(%lf,%lf)", &xj, &yj) != 2)
			quitf(_fail, "Test %d. Wrong judge answer format: %s", nt, sans.c_str());
		string sout = ouf.readString();
		double xa, ya;
		if (sscanf(sout.c_str(), "(%lf,%lf)", &xa, &ya) != 2)
			quitf(_wa, "Test %d. Wrong output format: %s", nt, sout.c_str());
		if (fabs(xa-xj) > 1E-6 || fabs(ya-yj) > 1E-6)
			quitf(_wa, "Test %d. Wrong answer: [judge] %s != %s [contestant]", nt, sans.c_str(), sout.c_str());
	}
	quitf(_ok, "OK. %d tests", nt);
}
