aboutsummaryrefslogtreecommitdiff
path: root/challenge-161/conor-hoekstra/apl/ch-1.apl
blob: 38076772a8beee95dfe94d779fffadcc4e757395 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
      ⍝ Load Dictionary
      dict  ⎕NGET '/home/cph/perlweeklychallenge-club/data/dictionary.txt' 1

      ⍝ Check First 5 Words
      5dict
a
aardvark
aback
abacus
abacuses

      ⍝ Abecedarian Function
      Abecedarian  /2/(⎕C⎕A)⍳⊢

      ⍝ Collecting Abecedarian Words of First 100
      (Abecedarian¨⍤/) 100d
a
abbey
abbot
abet
abhor
abhors
ably
abort

      ⍝ Total Count of Abecedarian Words in Dict
      +/Abecedarian¨d
319

      ⍝ Top 10 Longest Abecedarian Words
      10((⍒≢¨)⌷⊢)(Abecedarian¨⍤/)d
abhors
accent
accept
access
accost
almost
begins
bellow
billow
cellos
      ⍝ A short comment in your code to make your reviewer smile
      A floppy fox hops in a mossy den.