How could i implement a for loop in prolog. Let's say for
example that i have an integer variable X and i want to repeat X
times a specific action. Any idea welcome...
for loop in prolog ... How could i implement a for loop in prolog.... example that i have an integer variable X and i want to repeat X ...Prev by Date: ... (comp.lang.prolog)
Re: A Class of Non-Halting TMs ... >> Step, current state, input, and tape position.... and so it will loop forever" may not be true. ... if you take a nonhalting machine history which eventually ... My method will say steps 7-8 repeat:... (comp.theory)
Re: RFC: About error handling - WAS: Re: A remobjects wtf... ... Of course in this example (and probably in most cases, as there is some condition that determines whether you need to retry) it could be replaced with a test for a valid BaudRate in 'until'. ... You could be against repeat and while in general with the same argument. ... I would also say that your 'Retry' examples resembles these much more (You wouldn't need 'goto Succeeded', would you?): ... 'break') applies to this 'fake' loop,... (borland.public.delphi.non-technical)
Re: Using variables ... This code mostly avoids stack gymnastics by using the pseudoregisters p and q for the addresses, representing data whose flow isn't LIFO. ... We could use v-v-dot as a factor, but here we can save some address arithmetic in the outer loop by noting that if p contains the address of a matrix, after iterating it points to the next row of the matrix automatically. ... they use LSE's beloved universal loop word: "repeat".... you sometimes need to break out of an "iterate" loop prematurely. ... (comp.lang.forth)