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:为什么我这段代码用C++提交才可以,C就不行(错误原因说是标识符未声明)

Posted by 1565493549 at 2017-11-20 17:19:11 on Problem 1005
In Reply To:为什么我这段代码用C++提交才可以,C就不行(错误原因说是标识符未声明) Posted by:SummerJY at 2014-04-20 12:35:05
> #include<stdio.h>
> const double PI=3.141592654;
> int main()
> {
> 
>     int n;
>     scanf("%d",&n);
>     int i=1;
>     for(i=1;i<=n;i++)
>     {
>         double x,y;
>         scanf("%lf%lf",&x,&y);
>         double Area;
>         Area=0.5*PI*(x*x+y*y);
>         int year;
>         year=(int)(Area/50.0+1.0);
>         printf("Property %d: This property will begin eroding in year %d.",i,year);
>         printf("\n");
> 
>     }
>     printf("END OF OUTPUT.");
>     return 0;
> }

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