Alternade words: Difference between revisions

Added Arturo implementation
(add FreeBASIC)
(Added Arturo implementation)
Line 608:
{{output}}
<lang applescript>{{alternade:"benevolent", subwords:{"belt", "eve", "non"}}, {alternade:"rejuvenate", subwords:{"rune", "eva", "jet"}}}</lang>
 
=={{header|Arturo}}==
<lang rebol>words: map read.lines relative "unixdict.txt" => strip
 
loop words 'word [
sw: size word
if 6 > sw ->
continue
 
alt1: join map select 0..dec size word => odd? 'x -> word\[x]
alt2: join map select 0..dec size word => even? 'x -> word\[x]
 
if and? [contains? words alt1][contains? words alt2] ->
print [word "=>" alt1 alt2]
]</lang>
 
{{out}}
 
<pre>accost => cot acs
accuse => cue acs
afield => fed ail
agleam => gem ala
alcott => lot act
allele => lee all
allied => lid ale
alpert => let apr
ambient => min abet
annette => net ante
apport => pot apr
ariadne => ran aide
assist => sit ass
battle => ate btl
blaine => lie ban
brenda => rna bed
calliope => aloe clip
choose => hoe cos
choosy => hoy cos
claire => lie car
collude => old clue
effete => fee eft
fabric => arc fbi
fealty => ely fat
fluent => let fun
forwent => own fret
friend => red fin
george => ere gog
inroad => nod ira
israel => sal ire
jaunty => any jut
joanne => one jan
lounge => one lug
oriole => roe oil
oswald => sad owl
parrot => art pro
peoria => era poi
pierre => ire per
poodle => ode pol
pounce => one puc
racial => ail rca
realty => ely rat
sordid => odd sri
spatial => pta sail
sprain => pan sri
strain => tan sri
strait => tat sri
sturdy => try sud
sweaty => way set
tattle => ate ttl
theorem => hoe term
though => huh tog
throaty => hot tray
triode => roe tid
triune => rue tin
troupe => rue top
truant => rat tun
twirly => wry til</pre>
 
=={{header|AutoHotkey}}==
1,532

edits