naive-3-sat
Version:
naive solver for the 3-sat problem
19 lines (15 loc) • 353 B
JavaScript
const { Visitor } = require('./Visitor');
class Evaluator {
constructor(asts) {
this.asts = asts;
this.visitor = new Visitor();
}
/*
* Recursively visits the evaluation tree and computes the result of the evaluation.
*
*/
evaluate() {
return this.visitor.visitExpressions(this.asts);
}
}
exports.Evaluator = Evaluator;