답안 #1113750

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
1113750 2024-11-17T10:23:00 Z EfeBabagil Sprinklers (CEOI24_sprinklers) C++14
3 / 100
28 ms 2128 KB
#include <bits/stdc++.h>
using namespace std;
#define int long long

int32_t main()
{
    int n,m;
    cin>>n>>m;
    vector<int> spr(n),flo(m);
    
    for(int i=0;i<n;i++)
    {
        cin>>spr[i];
    }
    int mn=LLONG_MAX;
    int mx=0;
    for(int i=0;i<m;i++)
    {
        cin>>flo[i];
        mn=min(mn,flo[i]);
        mx=max(mx,flo[i]);
    }
    if(spr[0]>=mx)
    {
        cout<<spr[0]-mn;
        cout<<endl;
        cout<<"L";
    }
    else if(spr[0]<=mn)
    {
        cout<<mx-spr[0];
        cout<<endl;
        cout<<"R";
    }
    else
    cout<<"-1";
    return 0;
}
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 336 KB User solution is worse than jury's solution
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 336 KB Correct
2 Correct 21 ms 1872 KB Correct
3 Correct 1 ms 504 KB Correct
4 Correct 28 ms 1972 KB Correct
5 Correct 26 ms 2128 KB Correct
6 Correct 1 ms 336 KB Correct
7 Correct 1 ms 336 KB Correct
8 Correct 6 ms 592 KB Correct
9 Correct 1 ms 336 KB Correct
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 336 KB User solution is worse than jury's solution
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 336 KB User solution is worse than jury's solution
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 336 KB User solution is worse than jury's solution
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 1 ms 336 KB User solution is worse than jury's solution
2 Halted 0 ms 0 KB -