ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1385. Interesting Number

Genuine Algo
Posted by jagatsastry 30 Nov 2007 23:59
Can anyone suggest a genuine method of solving this problem. i.e. not a method such as

    if(n==1) printf("14");
    else if(n==2) printf("155");
    else
    {
        printf("1575");
        for(i=3;i<n;i++)
        printf("0");
    }
Re: Genuine Algo
Posted by Denis Koshman 24 Jul 2008 11:45


Edited by author 24.07.2008 12:02
Re: Genuine Algo
Posted by Denis Koshman 24 Jul 2008 11:48


Edited by author 24.07.2008 12:02
Re: Genuine Algo
Posted by Drema [KhAI] Tihov Ilya 19 Jun 2009 04:37
I have solution ... right solution, but I have TLE #4 ... It's so slowly.
Re: Genuine Algo
Posted by Baurzhan 2 Oct 2009 21:46
Yes,this problem has genuine algo: this is just a formula. Try to get it by yourself using this hint: write general formula for interesting numbers on paper and try to find what numbers are impossible and vise-versa. If you want see my code send me mail to bauracm@mail.ru