F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_39139585_25767.cpp: In function 'int main()':
0_0_39139585_25767.cpp:45:9: error: 'ios' has not been declared
   45 |         ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);
      |         ^~~
0_0_39139585_25767.cpp:45:37: error: 'cin' was not declared in this scope
   45 |         ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);
      |                                     ^~~
0_0_39139585_25767.cpp:9:1: note: 'std::cin' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
    8 | #include<cstring>
  +++ |+#include <iostream>
    9 | using namespace std;
0_0_39139585_25767.cpp:45:48: error: 'cout' was not declared in this scope
   45 |         ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);
      |                                                ^~~~
0_0_39139585_25767.cpp:45:48: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
0_0_39139585_25767.cpp:51:36: error: 'endl' was not declared in this scope
   51 |                         cout<<"0"<<endl;
      |                                    ^~~~
0_0_39139585_25767.cpp:9:1: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
    8 | #include<cstring>
  +++ |+#include <ostream>
    9 | using namespace std;
0_0_39139585_25767.cpp:56:37: error: 'endl' was not declared in this scope
   56 |                         cout<<"-1"<<endl;
      |                                     ^~~~
0_0_39139585_25767.cpp:56:37: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
0_0_39139585_25767.cpp:69:45: error: 'endl' was not declared in this scope
   69 |                 if(tp.size()<n) cout<<"-1"<<endl;
      |                                             ^~~~
0_0_39139585_25767.cpp:69:45: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?
0_0_39139585_25767.cpp:77:36: error: 'endl' was not declared in this scope
   77 |                         cout<<ans<<endl;
      |                                    ^~~~
0_0_39139585_25767.cpp:77:36: note: 'std::endl' is defined in header '<ostream>'; did you forget to '#include <ostream>'?


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-22 22:36:19, Gzip enabled