ENG  RUSTimus Online Judge
Online Judge
Задачи
Авторы
Соревнования
О системе
Часто задаваемые вопросы
Новости сайта
Форум
Ссылки
Архив задач
Отправить на проверку
Состояние проверки
Руководство
Регистрация
Исправить данные
Рейтинг авторов
Текущее соревнование
Расписание
Прошедшие соревнования
Правила
вернуться в форум

Обсуждение задачи 1125. Классики

HINT for WA2
Послано tiancaihb 15 авг 2009 11:25
The statement is poor. It says M*N, which is usually considered as M in x-axis and N in y-axis.
But actually, for M=2,N=3 they mean
xxx
xxx
(That can be infered from "The next M lines contain a matrix with nonnegative integer elements")
And we can't understand that from Sample because it's a square!

***  So,if you always get WA2,try to swap m,n.  ***
I changed scanf("%d %d",&m,&n) to scanf("%d %d",&n,&m) and got AC.
Sorry for my poor English.

Edited by author 15.08.2009 11:30

Edited by author 15.08.2009 11:31
Re: HINT for WA2
Послано Jane Soboleva (SumNU) 2 окт 2015 16:40
Nevermind, i'm stupid... another hint for WA #2: when generate your numbers a^2+b^2=c^2, and then you invert things like (+3X, +4X) for X=1...while coordinates are valid, and then later you want to invert (+6X, +8X) — don't! Because you invert the same place once more.

Edited by author 02.10.2015 16:50