| ||||||||||
| Online Judge | Problem Set | Authors | Online Contests | User | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest | |||||||||
Re:对这题无语了,两个程序没有什么区别呀!就是一个WA,一个AC。。。。。。。In Reply To:对这题无语了,两个程序没有什么区别呀!就是一个WA,一个AC。。。。。。。 Posted by:bjss222 at 2007-10-26 12:24:55 > /*
> //WA
> #include<iostream.h>
>
> int main(){
> int i,n,x,y,z;
> cout.precision(8);
> while(cin>>x>>y>>z>>n){
> for(i=0; i<n; i++) cout<<"0 0 "<<1.0*z*i/n<<" "<<x<<" "<<y<<" "<<1.0*z*(i+1)/n<<endl;
~~~多空格了
> }
> return 0;
> }
> */
>
>
> //2834445 bjss222 3103 Accepted 164K 45MS C++ 199B 2007-10-26 12:21:54
> #include<stdio.h>
>
> int main(){
> int i,n,x,y,z;
> while(scanf("%d%d%d%d",&x,&y,&z,&n)!=EOF){
> for(i=0; i<n; i++) printf("0 0 %.8lf %d %d %.8lf\n", 1.0*z*i/n,x,y,1.0*(i+1)*z/n);
> }
> return 0;
> }
Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator