initial draft of a pangram checker

FossilOrigin-Name: eff99290b7fbced8e754a6b45005a8d860339158ddf22907ee1483712ea72c57
This commit is contained in:
crc 2017-10-22 19:04:31 +00:00
parent 578870c912
commit b07f8a82f6

14
example/is-pangram.forth Normal file
View file

@ -0,0 +1,14 @@
~~~
{{
'abcdefghijklmnopqrstuvwxyz 'FULL s:const
'__________________________ 'TEST s:const
---reveal---
:s:pangram? (s-f)
'__________________________ &TEST #26 copy
s:to-lower [ c:letter? ] s:filter [ dup $a - &TEST + store ] s:for-each
&TEST &FULL s:eq? ;
}}
~~~
'Hello_world! s:pangram?
'The_quick_brown_fox_jumped_over_the_lazy_dogs. s:pangram?