16 lines
334 B
Plaintext
16 lines
334 B
Plaintext
program amb;
|
|
|
|
sets := unstr('[{the that a} {frog elephant thing} {walked treaded grows} {slowly quickly}]');
|
|
|
|
words := [amb(words): words in sets];
|
|
if exists lWord = words(i), rWord in {words(i+1)} |
|
|
lWord(#lWord) /= rWord(1) then
|
|
fail;
|
|
end if;
|
|
|
|
proc amb(words);
|
|
return arb {word in words | ok};
|
|
end proc;
|
|
|
|
end program;
|