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_38721776_28316.cpp: In function 'void sol1()':
0_0_38721776_28316.cpp:18:5: error: 'unordered_map' was not declared in this scope
   18 |     unordered_map<int, int> f;
      |     ^~~~~~~~~~~~~
0_0_38721776_28316.cpp:3:1: note: 'std::unordered_map' is defined in header '<unordered_map>'; did you forget to '#include <unordered_map>'?
    2 | #include<map>
  +++ |+#include <unordered_map>
    3 | #define ll long long
0_0_38721776_28316.cpp:18:19: error: expected primary-expression before 'int'
   18 |     unordered_map<int, int> f;
      |                   ^~~
0_0_38721776_28316.cpp:20:24: error: 'f' was not declared in this scope
   20 |     while(len<maxn && !f.count(cur)){
      |                        ^
0_0_38721776_28316.cpp:25:5: error: 'vector' was not declared in this scope
   25 |     vector<int> s(n), is(n);
      |     ^~~~~~
0_0_38721776_28316.cpp:3:1: note: 'std::vector' is defined in header '<vector>'; did you forget to '#include <vector>'?
    2 | #include<map>
  +++ |+#include <vector>
    3 | #define ll long long
0_0_38721776_28316.cpp:25:12: error: expected primary-expression before 'int'
   25 |     vector<int> s(n), is(n);
      |            ^~~
0_0_38721776_28316.cpp:26:12: error: expected primary-expression before 'int'
   26 |     vector<int> d(n);
      |            ^~~
0_0_38721776_28316.cpp:28:14: error: 's' was not declared in this scope
   28 |         cin>>s[i]>>d[i];
      |              ^
0_0_38721776_28316.cpp:28:20: error: 'd' was not declared in this scope
   28 |         cin>>s[i]>>d[i];
      |                    ^
0_0_38721776_28316.cpp:29:18: error: 'is' was not declared in this scope; did you mean 'i'?
   29 |         if(s[i]) is[i] = qm(s[i], P-2, P);
      |                  ^~
      |                  i
0_0_38721776_28316.cpp:35:43: error: 's' was not declared in this scope
   35 |             for(int i = 0; i < n; ++i) if(s[i]==0) ans++;
      |                                           ^
0_0_38721776_28316.cpp:38:20: error: 's' was not declared in this scope
   38 |                 if(s[i] == 0) continue;
      |                    ^
0_0_38721776_28316.cpp:39:33: error: 'is' was not declared in this scope; did you mean 'i'?
   39 |                 ll ak = (ll)x * is[i] % P;
      |                                 ^~
      |                                 i
0_0_38721776_28316.cpp:40:20: error: 'f' was not declared in this scope
   40 |                 if(f.count(ak) && f[ak] <= d[i]) ans++;
      |                    ^
0_0_38721776_28316.cpp:40:44: error: 'd' was not declared in this scope
   40 |                 if(f.count(ak) && f[ak] <= d[i]) ans++;
      |                                            ^


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.000000(s) query 1, Server time : 2025-01-10 21:24:13, Gzip enabled