Need help finding a pithy corouting example

D

Dave Thomas

I'm looking for a concise but interesting example of corotuines to
illustrate symmetrical fibers for the 1.9 edition of the PickAxe.

Way back in the dim past, I remember a logic puzzle to do with laying
down a path of colored tiles such that there were no repeating
subsequences. I remember coding a solution using coroutines in Simula.
But I can't now find a formulation of the problem. Does anyone know
it? Or can anyone suggest an alternative illustration of coroutines
that will fit in about 20-30 lines.?

Thanks


Dave
 
B

bullockbefriending bard

I'm looking for a concise but interesting example of corotuines to  
illustrate symmetrical fibers for the 1.9 edition of the PickAxe.

Way back in the dim past, I remember a logic puzzle to do with laying  
down a path of colored tiles such that there were no repeating  
subsequences. I remember coding a solution using coroutines in Simula.  
But I can't now find a formulation of the problem. Does anyone know  
it? Or can anyone suggest an alternative illustration of coroutines  
that will fit in about 20-30 lines.?

Thanks

Dave

Chapter 9 - Coroutines in Programming in Lua has a few examples.

Chapter 13.4 in Teach Yourself Scheme in Fixnum days has a tree-
matching example.

Both are available in online versions.
 
D

Dave Thomas

Chapter 9 - Coroutines in Programming in Lua has a few examples.

Chapter 13.4 in Teach Yourself Scheme in Fixnum days has a tree-
matching example.

Both are available in online versions.

I should have said: I saw those, but I was looking for something a
little more fun :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top