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_17507760_14857.cpp: In function 'T& RD(T&)':
0_0_17507760_14857.cpp:6:30: error: there are no arguments to 'getchar' that depend on a template parameter, so a declaration of 'getchar' must be available [-fpermissive]
     char c; for (c = getchar(); c < '0'; c = getchar()); x = c - '0'; for (c = getchar(); '0' <= c && c <= '9'; c = getchar()) x = x * 10 + c - '0';
                              ^
0_0_17507760_14857.cpp:6:30: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
0_0_17507760_14857.cpp:6:54: error: there are no arguments to 'getchar' that depend on a template parameter, so a declaration of 'getchar' must be available [-fpermissive]
     char c; for (c = getchar(); c < '0'; c = getchar()); x = c - '0'; for (c = getchar(); '0' <= c && c <= '9'; c = getchar()) x = x * 10 + c - '0';
                                                      ^
0_0_17507760_14857.cpp:6:88: error: there are no arguments to 'getchar' that depend on a template parameter, so a declaration of 'getchar' must be available [-fpermissive]
     char c; for (c = getchar(); c < '0'; c = getchar()); x = c - '0'; for (c = getchar(); '0' <= c && c <= '9'; c = getchar()) x = x * 10 + c - '0';
                                                                                        ^
0_0_17507760_14857.cpp:6:125: error: there are no arguments to 'getchar' that depend on a template parameter, so a declaration of 'getchar' must be available [-fpermissive]
     char c; for (c = getchar(); c < '0'; c = getchar()); x = c - '0'; for (c = getchar(); '0' <= c && c <= '9'; c = getchar()) x = x * 10 + c - '0';
                                                                                                                             ^
0_0_17507760_14857.cpp: At global scope:
0_0_17507760_14857.cpp:23:1: error: 'vector' does not name a type
 vector <int> pos[N];
 ^
0_0_17507760_14857.cpp: In function 'void add(int, int)':
0_0_17507760_14857.cpp:49:47: error: 'lowbit' was not declared in this scope
     for (int i = idx ; i <= n ; i += lowbit (i))
                                               ^
0_0_17507760_14857.cpp: In function 'int sum(int)':
0_0_17507760_14857.cpp:54:46: error: 'lowbit' was not declared in this scope
     for (int i = idx ; i > 0 ; i -= lowbit (i))
                                              ^
0_0_17507760_14857.cpp: In function 'int main()':
0_0_17507760_14857.cpp:69:13: error: 'pos' was not declared in this scope
             pos[i].clear ();
             ^
0_0_17507760_14857.cpp:70:34: error: 'memset' was not declared in this scope
         memset (p , 0 , sizeof(p));
                                  ^
0_0_17507760_14857.cpp:74:49: error: 'max' was not declared in this scope
                 idx = max (idx , p[fac[a[i]][j]]);
                                                 ^
0_0_17507760_14857.cpp:78:13: error: 'pos' was not declared in this scope
             pos[idx].push_back (i);
             ^
0_0_17507760_14857.cpp:84:49: error: 'min' was not declared in this scope
                 idx = min (idx , p[fac[a[i]][j]]);
                                                 ^
0_0_17507760_14857.cpp:91:24: error: 'sort' was not declared in this scope
         sort (q , q + m);
                        ^
0_0_17507760_14857.cpp:105:38: error: 'pos' was not declared in this scope
                 for (int j = 0 ; j < pos[left].size() ; j ++) {
                                      ^
0_0_17507760_14857.cpp:115:36: error: 'printf' was not declared in this scope
             printf ("%d\n" , ans[i]);
                                    ^
0_0_17507760_14857.cpp: In instantiation of 'T& RD(T&) [with T = int]':
0_0_17507760_14857.cpp:14:13:   required from here
0_0_17507760_14857.cpp:6:30: error: 'getchar' was not declared in this scope
     char c; for (c = getchar(); c < '0'; c = getchar()); x = c - '0'; for (c = getchar(); '0' <= c && c <= '9'; c = getchar()) x = x * 10 + c - '0';
                              ^
0_0_17507760_14857.cpp:6:88: error: 'getchar' was not declared in this scope
     char c; for (c = getchar(); c < '0'; c = getchar()); x = c - '0'; for (c = getchar(); '0' <= c && c <= '9'; c = getchar()) x = x * 10 + c - '0';
                                                                                        ^


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-17 02:39:11, Gzip enabled