Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

Re:Presentation Error错误,做过这题的兄弟帮忙看一下问题在哪

Posted by frkstyc at 2005-12-26 16:51:12 on Problem 2710
In Reply To:Presentation Error错误,做过这题的兄弟帮忙看一下问题在哪 Posted by:hudedi at 2005-12-26 16:39:42
> /*pku 2710*/
> #include<stdio.h>
> int main()
> {
>     double n,d,b,e,n1;
>     int digit10;
>     int out;
>     int times;
>     int ii,jj,kk;
>     scanf("%d",×);
>     for(ii=1;ii<=times;ii++)
>     {
>          scanf("%lf%lf%lf%lf",&n1,&d,&b,&e);
>          n=(int)n1%(int)d;
>          jj=b;
>          while(jj--)
>                 n=7*(int)n%(int)d;
>          printf("Problem set %d: %.0lf / %.0lf,base 7 digits %.0lf through %.0lf:",ii,n1,d,b,e);
                                               ~~~空格
>          for(kk=0;kk<e+1-b;kk++)
>          {
> 
>              printf("%d",out=(int)(7*((int)n%(int)d/d)));
>              n=7*(int)n%(int)d;
>          }
>          printf("\n");
> 
>     }
>     return 1;
> }
> 

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator