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_23192749_27700.cpp: In function 'void dfs(int*)':
0_0_23192749_27700.cpp:55:115: error: reference to 'cout' is ambiguous
 {int last;for(int i=8; i>-1; i--) if(means[i]!=0) {last=i; break;}  for(int i=0; i<last; i++) while(means[i]!=0) {cout<<i+1<<' '; --means[i];}
                                                                                                                   ^
0_0_23192749_27700.cpp:6:14: note: candidates are: std::ofstream cout
     ofstream cout ("clocks.out");
              ^
In file included from 0_0_23192749_27700.cpp:1:0:
GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:61:18: note:                 std::ostream std::cout
   extern ostream cout;  /// Linked to standard output
                  ^
0_0_23192749_27700.cpp:56:24: error: reference to 'cout' is ambiguous
   while(means[last]>1){cout<<last+1<<' '; --means[last];}cout<<last+1<<endl;     }
                        ^
0_0_23192749_27700.cpp:6:14: note: candidates are: std::ofstream cout
     ofstream cout ("clocks.out");
              ^
In file included from 0_0_23192749_27700.cpp:1:0:
GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:61:18: note:                 std::ostream std::cout
   extern ostream cout;  /// Linked to standard output
                  ^
0_0_23192749_27700.cpp:56:58: error: reference to 'cout' is ambiguous
   while(means[last]>1){cout<<last+1<<' '; --means[last];}cout<<last+1<<endl;     }
                                                          ^
0_0_23192749_27700.cpp:6:14: note: candidates are: std::ofstream cout
     ofstream cout ("clocks.out");
              ^
In file included from 0_0_23192749_27700.cpp:1:0:
GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:61:18: note:                 std::ostream std::cout
   extern ostream cout;  /// Linked to standard output
                  ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2025 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.001000(s) query 1, Server time : 2025-02-17 07:43:11, Gzip enabled