src/drone.cpp
//TODO: find alternative to avoid checking all objects for position
find alternative to avoid checking all objects for position
find alternative to avoid checking all objects for position
bool DRONE::EmptyCell(const DRONE_STATE &droneState, const COORD &coord) const {
    bool empty = true;
    for (int i = 0; i < droneState.Features.size() && empty; i++){
        if (droneState.Features[i].Position == coord)
            empty = false;
    }
    return empty;
}
bool DRONE :: EmptyCell ( const DRONE_STATE & droneState , const COORD & coord ) const { bool empty = true ; for ( int i = 0 ; i < droneState . Features . size ( ) && empty ; i ++ ) { if ( droneState . Features [ i ] . Position == coord ) empty = false ; } return empty ; }
TODO: find alternative to avoid checking all objects for position
TODO : find alternative to avoid checking all objects for position
// If there is anything, not empty