view src/ploki/examples/fibcheck.pk @ 9473:9a4a5b747a91

<oerjan> slwd religious nut//s/ This/The religious/
author HackBot
date Thu, 27 Oct 2016 01:29:38 +0000
parents ac0403686959
children
line wrap: on
line source

#!../ploki
REM fibonacci sequence tester
REM sample input:
REM x x xx xxx xxxxx
REM x x x
FOR line LET line @LEGS \EING
	IF line ; ""
		IF line ~ "^s!*({[S!|[{S!}|[2!|1![1]?]{0!}[2]?][0]?]}s!+)+$"
			"fibonacci sequence!
		ELSE
			"nope...
		FI
		NEXT line
	FI