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

Обсуждение задачи 1493. В одном шаге от счастья

ADMINS: Possible missing definition
Послано Amndeep Singh Mann 24 янв 2012 02:29
Now, I could be saying something stupid here.  But I think we're missing a definition of what happens at the topmost boundary.
Say our number is 999,999, if you subtract one, you don't get a lucky number, but if you add one, then what happens?
The problem said that it was going to be a 6 digit number at all times, but if you add one, it becomes a seven digit number, so does this case never occur?  And if it does, then does the lucky number formula apply only to the last 6 digits of the number?
Re: ADMINS: Possible missing definition
Послано Sandro (USU) 24 янв 2012 02:45
You are right. In fact all the tram tickets have exactly 6 digits, so ticket 1000000 doesn't exist. I have added this phrase to the hint.
Re: ADMINS: Possible missing definition
Послано SquidBoy 24 апр 2012 06:48
It doesn't really matter, because the problem definition says the sum of the first 3 and last 3 digits differs by one.  999,998 fits this definition, but 999,999 does not.