Submission #276452

# Submission time Handle Problem Language Result Execution time Memory
276452 2020-08-20T12:56:38 Z JuliusMieliauskas Colouring a rectangle (eJOI19_colouring) C++14
0 / 100
121 ms 12048 KB
#include <bits/stdc++.h>

using namespace std;

#define all(x) x.begin(), x.end()
#define vi vector<int>
#define vll vector<long long>
#define MOD 1000000007
#define endl '\n'

typedef long long ll;

void print(vi v){
    cout<<"Contents of vector:\n";
    for(auto x : v) cout<<x<<" ";
    cout<<endl<<endl;
}

void solve(){
    int m, n; cin>>m>>n;

    int l[m+n-1], r[m+n-1];

    for(int i = 0; i<m+n-1; i++) cin>>l[i];

    for(int i = 0; i<m+n-1; i++) cin>>r[i];

    if(m == 1){
        ll ans = 0;
        for(int i = 0; i<m+n-1; i++){
            ans += min(l[i], r[i]);
        }
        cout<<ans<<endl;
        return;
    }
}

int main() {
    ios_base::sync_with_stdio(false); cin.tie(nullptr);
    //ifstream cin(""); ofstream cout("");///cia failai

    //int T; cin>>T;
    int T = 1;

    for(int it = 1; it<=T; it++){
        solve();

    }
}
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 384 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 384 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 384 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 384 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 51 ms 5840 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 121 ms 12048 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 384 KB Output isn't correct
2 Halted 0 ms 0 KB -