Submission #232357

# Submission time Handle Problem Language Result Execution time Memory
232357 2020-05-16T20:02:18 Z jam_xd_ Gondola (IOI14_gondola) C++17
Compilation error
0 ms 0 KB
#include "ricehub.h"
#include <bits/stdc++.h>
int besthub(int R, int L, int X[], long long B)
{
int rhub = 1;//thub=0;

int operaciones = 0, c_hub=0;

multiset<int>dinamic_multiset;

for(int i=0;i<X.size();i++){
	if(rhub <= X[i]){
		for(int j=X[i];j>=rhub;j++){
			operaciones++;

			if(operaciones >= B){
				dinamic_multiset.insert(c_hub);
				operaciones=0;
				c_hub=0;
				break;
			}
		}
		c_hub++;

	
	}

	if(rhub >= X[i]){
		for(int j=X[i];j<=rhub;j++){
			operaciones++;

			if(operaciones>=B){
				dinamic_multiset.insert(c_hub);
				operaciones = 0;
				c_hub=0;
				break;
    		}
		}
		c_hub++;
	
	}
}
multiset<int>::iterator it = dinamic_multiset.end();
for(it = dinamic_multiset.begin(); it != dinamic_multiset.end(); it++){
	if(it != dinamic_multiset.end())R = (*it);
}
/////////////////////////////////////////////////////////////////////

	/*for(int i=1;i<=L;i++){

	}*/





  return R;
}

Compilation message

gondola.cpp:1:10: fatal error: ricehub.h: No such file or directory
 #include "ricehub.h"
          ^~~~~~~~~~~
compilation terminated.