/ Vijos /

记录详情

Compile Error

foo.cc: In function 'int main()':
foo.cc:18:9: error: 'cin' was not declared in this scope
   18 |         cin>>x1>>x2>>v1>>v2>>len;
      |         ^~~
foo.cc:5:1: note: 'std::cin' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
    4 | #include<algorithm>
  +++ |+#include <iostream>
    5 | using namespace std;
foo.cc:37:17: error: 'cout' was not declared in this scope
   37 |                 cout<<"Impossible"<<endl;
      |                 ^~~~
foo.cc:37:17: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
foo.cc:37:37: error: 'endl' was not declared in this scope
   37 |                 cout<<"Impossible"<<endl;
      |                                     ^~~~
foo.cc:5:1: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
    4 | #include<algorithm>
  +++ |+#include <ostream>
    5 | using namespace std;
foo.cc:42:25: error: 'cout' was not declared in this scope
   42 |                         cout<<(dx*k/d)%len<<endl;
      |                         ^~~~
foo.cc:42:25: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
foo.cc:42:45: error: 'endl' was not declared in this scope
   42 |                         cout<<(dx*k/d)%len<<endl;
      |                                             ^~~~
foo.cc:42:45: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
foo.cc:44:25: error: 'cout' was not declared in this scope
   44 |                         cout<<((len+k)*dx/d)%len<<endl;
      |                         ^~~~
foo.cc:44:25: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
foo.cc:44:51: error: 'endl' was not declared in this scope
   44 |                         cout<<((len+k)*dx/d)%len<<endl;
      |                                                   ^~~~
foo.cc:44:51: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1009 清帝之惑之康熙
语言
C++
递交时间
2022-08-17 12:55:12
评测时间
2022-08-17 12:55:12
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes