Cycle detection: Difference between revisions
→{{header|jq}}: move specifics to the end
(→{{header|jq}}: move specifics to the end) |
|||
Line 1,304:
|.lambda += 1 )
| {lambda, mu} ;
def f: (.*. + 1) % 255;▼
def task(f; x0):
Line 1,315 ⟶ 1,313:
"Cycle:",
skip(.mu; limit((.lambda + .mu); 3 | recurse(f)));
</lang>
'''The specific function and task'''
<lang jq>
▲def f: (.*. + 1) % 255;
task(f;3)
|