Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
25
Task/Eertree/Ring/eertree.ring
Normal file
25
Task/Eertree/Ring/eertree.ring
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
# Project : Eertree
|
||||
|
||||
str = "eertree"
|
||||
pal = []
|
||||
for n=1 to len(str)
|
||||
for m=1 to len(str)
|
||||
strrev = ""
|
||||
strpal = substr(str, n, m)
|
||||
if strpal != ""
|
||||
for p=len(strpal) to 1 step -1
|
||||
strrev = strrev + strpal[p]
|
||||
next
|
||||
if strpal = strrev
|
||||
add(pal, strpal)
|
||||
ok
|
||||
ok
|
||||
next
|
||||
next
|
||||
sortpal = sort(pal)
|
||||
for n=len(sortpal) to 2 step -1
|
||||
if sortpal[n] = sortpal[n-1]
|
||||
del(sortpal, n)
|
||||
ok
|
||||
next
|
||||
see sortpal + nl
|
||||
Loading…
Add table
Add a link
Reference in a new issue