#3597
Dyson
Într-un viitor îndepărtat, Federația Galactică își extinde influența asupra sistemului solar Aldebaran prin construirea unei megastructuri denumite Sferă Dyson, care să furnizeze energia necesară pentru terraformarea planetelor și zborul interstelar. Pentru a maximiza fluxul de energie captat de Sferă, Federația realizează o serie de modificări succesive în structura acesteia, propunându-și să analizeze pentru fiecare configurație în parte eficiența transferului de plasmă.
Problema | Dyson | Operații I/O |
dyson.in /dyson.out
|
---|---|---|---|
Limita timp | 0.75 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #24349551 | Utilizator | |
Fișier | dyson.cpp | Dimensiune | 5.95 KB |
Data încărcării | 06 Octombrie 2020, 17:27 | Scor / rezultat | Eroare de compilare |
dyson.cpp: In member function 'dinic<C, R>::result_type dinic<C, R>::max_flow(int, int, std::vector<_RealType>&)': dyson.cpp:58:30: error: parameter declared 'auto' auto find_path = [&](auto self, int from, flow_type res) ^ dyson.cpp: In lambda function: dyson.cpp:66:28: error: 'self' was not declared in this scope flow_type push = self(self, e.dst, std::min(res, e.cap - flow_e[e.flowp])); ^ dyson.cpp: In member function 'dinic<C, R>::result_type dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&)': dyson.cpp:87:29: error: parameter declared 'auto' auto find_path = [&](auto self, int from, flow_type res) ^ dyson.cpp: In lambda function: dyson.cpp:96:27: error: 'self' was not declared in this scope flow_type push = self(self, e.dst, std::min(res, e.cap - flow_e[e.flowp])); ^ dyson.cpp: In instantiation of 'dinic<C, R>::dinic(int) [with C = int; R = int]': dyson.cpp:213:16: required from here dyson.cpp:133:19: warning: 'dinic<int>::edge_pos' will be initialized after [-Wreorder] std::vector<int> edge_pos; ^ dyson.cpp:128:6: warning: 'int dinic<int>::flow_id' [-Wreorder] int flow_id; ^ dyson.cpp:29:2: warning: when initialized here [-Wreorder] dinic(int n) : adj(n), que(n), level(n), edge_pos(n), flow_id(0) {} ^ dyson.cpp: In instantiation of 'dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda4': dyson.cpp:65:10: required from 'struct dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda4' dyson.cpp:77:4: required from 'dinic<C, R>::result_type dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]' dyson.cpp:221:37: required from here dyson.cpp:66:79: error: 'self' was not declared in this scope flow_type push = self(self, e.dst, std::min(res, e.cap - flow_e[e.flowp])); ^ dyson.cpp: In instantiation of 'dinic<C, R>::result_type dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]': dyson.cpp:221:37: required from here dyson.cpp:78:58: error: no match for call to '(dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda4) (dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda4&, int&, const flow_type&)' for (flow_type f; (f = find_path(find_path, source, oo)) > 0;) ^ dyson.cpp:58:23: note: candidate is: auto find_path = [&](auto self, int from, flow_type res) ^ dyson.cpp:58:59: note: dinic<C, R>::max_flow(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda4 auto find_path = [&](auto self, int from, flow_type res) ^ dyson.cpp:58:59: note: candidate expects 2 arguments, 3 provided dyson.cpp: In instantiation of 'dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda5': dyson.cpp:95:30: required from 'struct dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda5' dyson.cpp:107:3: required from 'dinic<C, R>::result_type dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]' dyson.cpp:237:62: required from here dyson.cpp:96:78: error: 'self' was not declared in this scope flow_type push = self(self, e.dst, std::min(res, e.cap - flow_e[e.flowp])); ^ dyson.cpp: In instantiation of 'dinic<C, R>::result_type dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]': dyson.cpp:237:62: required from here dyson.cpp:116:40: error: no match for call to '(dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda5) (dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda5&, int&, const flow_type&)' f = find_path(find_path, source, oo); ^ dyson.cpp:87:22: note: candidate is: auto find_path = [&](auto self, int from, flow_type res) ^ dyson.cpp:87:58: note: dinic<C, R>::max_flow2(int, int, std::vector<_RealType>&) [with C = int; R = int; dinic<C, R>::result_type = int]::__lambda5 auto find_path = [&](auto self, int from, flow_type res) ^ dyson.cpp:87:58: note: candidate expects 2 arguments, 3 provided
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Dyson face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.