Exactly three adjacent 3 in lists: Difference between revisions
→{{header|Ring}}
Thundergnat (talk | contribs) m (→{{header|Raku}}: white space) |
|||
Line 120:
=={{header|Ring}}==
<lang ring>
see "working..." + nl
Line 129:
list[3] = [1,4,3,6,7,3,8,3,2]
list[4] = [1,2,3,4,5,6,7,8,9]
list[5] = [
for n = 1 to 5
strn = list2str(list[n])
cnt = count(strn,"3")
if cnt
for m = 1 to len(list[n])-
if list[n][m] = 3 and list[n][m+1] = 3 and list[n][m+2] = 3
flag = 1
exit
|