Question

One of the esoteric languages introduce ComeFrom command, which is opposite of Goto:

10 ComeFrom 30
20
30 ...

Equals to:

10 ...
20 ...
30 Goto 10

My question is: how to implement a conditional jump with ComeFrom?

Was it helpful?

Solution

As you said it would be just a "reversed goto". So do it like you would do it normally but instead writing got to the origin of the jumo, write ComeFrom to the destination

10 ComeFrom 80
20 ... Do something when Codition is true
30 ...
...
...
70 If condition Do
80 ...
90 ComeFrom 30

(I'm not quite sure if i understood your problem correct)

Out of interest: Which language are you referring to ?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top