Submission #625998

# Submission time Handle Problem Language Result Execution time Memory
625998 2022-08-11T06:07:51 Z aryan12 Catfish Farm (IOI22_fish) C++17
0 / 100
83 ms 7288 KB
#include "fish.h"
 
#include <bits/stdc++.h>
using namespace std;
 
long long max_weights(int N, int M, std::vector<int> X, 
    std::vector<int> Y, std::vector<int> W) {
    long long ans1 = 0, ans2 = 0;
    for(int i = 0; i < W.size(); i++)
    {
        if(X[i] == 0) ans1 += W[i];
        else ans2 += W[i];
    }
    return max(ans1, ans2); // subtask 1
}

Compilation message

fish.cpp: In function 'long long int max_weights(int, int, std::vector<int>, std::vector<int>, std::vector<int>)':
fish.cpp:9:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
    9 |     for(int i = 0; i < W.size(); i++)
      |                    ~~^~~~~~~~~~
# Verdict Execution time Memory Grader output
1 Correct 24 ms 2140 KB Output is correct
2 Correct 30 ms 2636 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 212 KB Output is correct
5 Correct 83 ms 7280 KB Output is correct
6 Incorrect 82 ms 7288 KB 1st lines differ - on the 1st token, expected: '300000000000000', found: '299997000000000'
7 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB 1st lines differ - on the 1st token, expected: '2', found: '1'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Incorrect 19 ms 1432 KB 1st lines differ - on the 1st token, expected: '21261825233649', found: '26722445760742'
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB 1st lines differ - on the 1st token, expected: '3', found: '2'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB 1st lines differ - on the 1st token, expected: '3', found: '2'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 212 KB 1st lines differ - on the 1st token, expected: '3', found: '2'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Incorrect 19 ms 1432 KB 1st lines differ - on the 1st token, expected: '21261825233649', found: '26722445760742'
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 24 ms 2140 KB Output is correct
2 Correct 30 ms 2636 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 212 KB Output is correct
5 Correct 83 ms 7280 KB Output is correct
6 Incorrect 82 ms 7288 KB 1st lines differ - on the 1st token, expected: '300000000000000', found: '299997000000000'
7 Halted 0 ms 0 KB -