Skip to content

Commit

Permalink
Restore state after planning in Hypertension_U task_permutations
Browse files Browse the repository at this point in the history
  • Loading branch information
Maumagnaguagno committed Oct 7, 2023
1 parent faa39c5 commit 42c819a
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Hypertension_U.rb
Original file line number Diff line number Diff line change
Expand Up @@ -144,10 +144,9 @@ def problem(state, tasks, debug = false, max_plans = -1, min_prob = 0, ordered =
def task_permutations(state, tasks)
# All permutations are considered
tasks.permutation {|task_list|
@state = state
task_list = Marshal.load(Marshal.dump(task_list))
planning(task_list)
planning(Marshal.load(Marshal.dump(task_list)))
return if @plans.size == @max_plans
@state = state
}
end
end

0 comments on commit 42c819a

Please sign in to comment.