제출 #138801

#제출 시각아이디문제언어결과실행 시간메모리
138801PedroBigManDetecting Molecules (IOI16_molecules)C++14
0 / 100
2 ms376 KiB
#include "molecules.h"
#include <iostream>
#include <vector>
#include <cmath>
#include <algorithm>
#include <string>
using namespace std;
typedef long long int ll;
typedef unsigned long long int ull;
typedef long double ld;
#define REP(i,a,b) for(ll i=a; i<b; i++)
#define pb push_back
#define mp make_pair
#define pl pair<ll,ll>
#define ff first
#define ss second
#define INF ((ll) pow(2,63) -1)
ll insig;
#define In(vecBRO, LENBRO) REP(IBRO,0,LENBRO) {cin>>insig; vecBRO.pb(insig);}
void Out(vector<ll> x) {REP(i,0,x.size()) {cout<<x[i]<<" ";} cout<<endl;}

std::vector<int> find_subset(int l, int u, std::vector<int> w) 
{
    ll we=w[0]; ll n = w.size();
    ll lo = (ll) ceil((ld) (l)/(ld) (we));
    ll hi = (ll) floor((ld) (u)/(ld) (we));
    vector<int> ans;
    if(lo<=hi && lo<=n) {REP(i,0,lo) {ans.pb((int) we);}}
    return ans;
}

컴파일 시 표준 에러 (stderr) 메시지

molecules.cpp: In function 'void Out(std::vector<long long int>)':
molecules.cpp:11:33: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
 #define REP(i,a,b) for(ll i=a; i<b; i++)
molecules.cpp:20:29:
 void Out(vector<ll> x) {REP(i,0,x.size()) {cout<<x[i]<<" ";} cout<<endl;}
                             ~~~~~~~~~~~~
molecules.cpp:20:25: note: in expansion of macro 'REP'
 void Out(vector<ll> x) {REP(i,0,x.size()) {cout<<x[i]<<" ";} cout<<endl;}
                         ^~~
#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...