Logo Search packages:      
Sourcecode: gcc-2.96 version File versions

bug-58741.cc

#include <deque>
#include <queue>
#include <vector>
#include <unistd.h>

template<class T>
T sqr(T a) {
    return a * a;
}

class Problem {
public:
    struct Move {       
        int dir;        
    };

    class State {
    public:
        static const int SIZE = 4;
        static const int FIELDMASK = (1 << SIZE) - 1;
        static const int BLANK = 0;

        explicit State(const vector<vector<int> >& nfields) { }

        State(const State& s, const Move& m) { }

        bool operator <(const State& other) const {
            return fields < other.fields;
        }

        deque<Move> moves() const {
            deque<Move> moves;

            int blanky;

            if (blanky < fields.size() - 1)
                moves.push_back(Move());

            return moves;
        }

        long fields;
    };

private:
    // use this for a variable goal
    State goal;

    int goalxpos[sqr(State::SIZE)];
    int goalypos[sqr(State::SIZE)];
};

Generated by  Doxygen 1.6.0   Back to index