Code: Select all
var word := "braveheart"
var nword : int
for scramword : 1 .. length (word)
if nword = 0 then
nword := word (1 .. scramword - 1) + word (scramword + 1 .. *) + word (scramword)
else
nword := word (2 .. *) + word
end if
put nword
end for[code]
[color=#888888][size=85]Archived topic from Iceteks, old topic ID:2863, old post ID:23386[/size][/color]