Submission #685697

#TimeUsernameProblemLanguageResultExecution timeMemory
685697Jovan26Catfish Farm (IOI22_fish)C++17
3 / 100
103 ms13908 KiB
#pragma once #include <bits/stdc++.h> using namespace std; #define ll long long long long max_weights(int N, int M, std::vector<int> X, std::vector<int> Y, std::vector<int> W){ bool st1 = true; for(int i=0;i<M;i++){ if(X[i]%2==1) st1 = false; } if(st1){ long long o = 0; for(int i=0;i<M;i++) o+=W[i]; return o; } ll o1 = 0; ll o2 = 0; for(int i=0;i<M;i++){ if(X[i]==0) o1+=W[i]; else o2+=W[i]; } ll o = max(o1,o2); return o; }

Compilation message (stderr)

fish.cpp:1:9: warning: #pragma once in main file
    1 | #pragma once
      |         ^~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...