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

Обсуждение задачи 1027. Снова D++

WA #1 HELP ME PLEASE I'D LIKE TO SOLVE THIS PROBLEM!!!
Послано Access Violation 6 янв 2008 02:47
Help please! I want to solve this problem, my program pass all the tests I've found in this forum successful! Why I've got WA on test 1! TELL ME PLEASE about this test! I can't understand what is wrong in my program!

P.S. My program pass these tests correctly:

(*)     - NO
(*(*)   - YES
(**)    - YES
(*8*)*) - NO
(       - NO
())(D   - NO

(123
321)    - YES

(1+2+3
)       - YES

qe()eq  - YES
q(())q  - YES

45(798+-
)(**)()  - YES


And task example text pass successful too.


Explain me please what is test 1. I can't solve this problem without this information.
Re: WA #1 HELP ME PLEASE I'D LIKE TO SOLVE THIS PROBLEM!!!
Послано alt (Uzhgorod NU) 6 янв 2008 03:04
First test must be example test, so check your input/output first.

P.S. This program passed test #1

#include <stdio.h>

int main()
{
printf("YES\n");
return 0;
}
Re: WA #1 HELP ME PLEASE I'D LIKE TO SOLVE THIS PROBLEM!!!
Послано Access Violation 6 янв 2008 12:44


Edited by author 06.01.2008 12:52
Re: WA #1 HELP ME PLEASE I'D LIKE TO SOLVE THIS PROBLEM!!!
Послано Access Violation 6 янв 2008 12:48
It's very strange. My program outputs 'YES' or 'NO', it's correct. But maybe I should read input data from text file? My current program reads input data in a cycle ('while') and reads it for symbols one by one.
Re: WA #1 HELP ME PLEASE I'D LIKE TO SOLVE THIS PROBLEM!!!
Послано Access Violation 6 янв 2008 12:51
Here is fragment of my code which reads input data. Answer me please, is it correct?

while( not eof ) do
 begin
  read( c );

 //...
 end;
Re: WA #1 HELP ME PLEASE I'D LIKE TO SOLVE THIS PROBLEM!!!
Послано Access Violation 6 янв 2008 18:01
I've verified, such reading method is correct. So, I can't understand where I've done a mistake. My program outputs YES while passing the example test. But I always get WA on test 1. Give me please the first test, I must solve this problem.