Data update
This commit is contained in:
parent
4bb20c9b71
commit
cbaf4c4b64
12390 changed files with 318560 additions and 27248 deletions
16
Task/Pangram-checker/ArkScript/pangram-checker.ark
Normal file
16
Task/Pangram-checker/ArkScript/pangram-checker.ark
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
(import std.String)
|
||||
(import std.List)
|
||||
(import std.Dict)
|
||||
|
||||
(let pangram? (fun (str) {
|
||||
(mut d (dict))
|
||||
(let keys
|
||||
(list:filter
|
||||
(list:map str (fun (c) (string:toLower c)))
|
||||
(fun (c) (!= -1 (string:find string:asciiLowercase c)))))
|
||||
(list:forEach keys
|
||||
(fun (k) (dict:add d k (if (nil? (dict:get d k)) 0 (+ 1 (dict:get d k))))))
|
||||
(= (len string:asciiLowercase) (len (dict:keys d))) }))
|
||||
|
||||
(print (pangram? "The quick brown fox jumps over the lazy dog"))
|
||||
(print (pangram? "abcdfghmnopqruvxy"))
|
||||
Loading…
Add table
Add a link
Reference in a new issue