Re: [eclipse-clp-users] Question on search/6

From: Joachim Schimpf <joachim.schimpf_at_...44...>
Date: Thu, 03 Sep 2009 10:33:11 +1000
Daniel Riera wrote:
> Ups!,
> 
> should I then do something like this?
> 
> (search(...,backtracks[N]) -> true;
>                                           getval(backtrack(BT),fail
> )

Yes, although you probably don't want to cut, so better

    (
        search(..., [backtrack(N)]),
        writeln(backtracks:N)
    ;
        getval(backtrack, N)_at_ic_search,
        writeln(backtracks:N),
        fail
    )


-- Joachim
Received on Thu Sep 03 2009 - 03:33:34 CEST

This archive was generated by hypermail 2.3.0 : Wed Sep 25 2024 - 15:13:20 CEST