https://github.com/vendethiel/trying.apl
APL is the greatest language ever
https://github.com/vendethiel/trying.apl
apl dyalog trying
Last synced: 4 days ago
JSON representation
APL is the greatest language ever
- Host: GitHub
- URL: https://github.com/vendethiel/trying.apl
- Owner: vendethiel
- Created: 2015-09-27T19:00:15.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2024-12-18T13:15:09.000Z (about 1 year ago)
- Last Synced: 2025-01-27T08:45:04.801Z (12 months ago)
- Topics: apl, dyalog, trying
- Language: APL
- Homepage:
- Size: 55.7 KB
- Stars: 68
- Watchers: 12
- Forks: 5
- Open Issues: 8
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Trying APL
This repository contains a handful of basic APL snippets, demonstrating each and every operator's purpose and behavior.
The `ex/` directory contains a few examples, mostly from Programming Puzzles & Code Golf Stack Exchange.
Table of contents
Evolution level: 1
Filename
Symbol name
Symbol
Monadic
Dyadic
Operator (higher-order)
assign
left arrow
←
Assignment
index
iota
⍳
Index Generator
Index of
reduce-replicate
slash
/
Replicate
Reduce
shaped
rho
⍴
Shape-of
Reshape
mix-take
up arrow
↑
Mix
Take
enclose
left shoe
⊂
Enclose
Partitioned enclose
first-pick
right shoe
⊃
First
Pick
rand
question mark
?
Roll
Deal
commute
tilde dieresis
⍨
Commute
element-s
epsilon
∊
Enlist (flat)
Membership
rev-rot
circle stile
⌽
Reverse (inner)
Rotate (inner)
rev-rot-first
circle bar
⊖
Reverse first (outer)
Rotate first (outer)
not-without
tilde
~
Not
Without
cat
comma
,
Ravel
Concatenate
logic
Logical {N,}{and,or}
∧, ∨, ⍲, ⍱
and, or, nand, nor
compare
{Not,} Equal | {Greater,Lower} than{,or equal}
<, >, ≤, ≥, =, ≠
lower, greater, lower-or-eq, greater-or-eq, eq, not-eq
grade
grade {up,down}
⍋ (up), ⍒ (down)
Grade {Up,Down}
Dyadic Grade {Up,Down}
each
dieresis
¨
Each
function
braces
{ and }
⍵ (monadic argument) / ⍵⍵ (function monadic argument)
⍺ (dyadic argument) / ⍺⍺ (function dyadic argument)
Function
depth-match
equal underbash
≡
Depth
Match
tally-notmatch
equal underbash slash
≢
Tally
Not-match
statement
diamond
⋄
Statement separator
short-circuit
colon
:
returns ⍵ from ∇ if ⍺=1
compose
jot
∘
Monadic compose (e.g.: ⍴∘⍴) / Currying
pointfree (implicit composition)
inner-product
dot
.
Inner product (e.g.: +.×)
outer-product
jot + dot
∘.
Outer product (e.g.: ∘.+)
rank
jot diaerisis
⍤
(⍵ is the new rank of the operator)
changes the rank of ⍺⍺
variant
quad colon
⍠
Sets option value
key
quad equal
⌸
Returns an scalar vector (key, positions for the key)