# Tag Info

### Tips for golfing in APL

Use to combine multiplication with addition (a×b)+C -> a⊥b,C (C)+a×b -> a⊥b,C (a×b)-C -> a⊥b,-C Assumptions: ...
• 15.2k

### Tips for golfing in APL

Complex numbers Often overlooked, they present wonderful opportunities to shorten expressions dealing with grids, mazes, fractals, or geometry. ...
• 15.2k

### Tips for golfing in APL

Tricks for dealing with / and in trains When using trains you may want to use reductions f/...
• 29.9k

### What valence does this APL train have?

Haskell, 61 bytes f t=[and$zipWith(/=)t$[2|even\$length t]++cycle[x,0]|x<-[2,0]] Try it online! Takes a list of: 0 for monad,...
• 68.1k

### Floor of complex number

BQN, 14 bytesSBCS ⌊+·(⍋×1<+´)1⊸| Try it here. ...
• 779

### Official Dyalog APL 2016 Year Game

Hexagony, 888 bytes Okay, first some ground rules for Hexagony, in case anyone wants to beat this: I'm interpreting "snippet" as a linear piece of code that can be dumped into any sufficiently large ...
• 196k

### Take that frown and turn it around

Python 3, 105 bytes lambda s:":⊢⍡⊣:▷⍢◁:⋆⍣⋆:∘⍤∘:○⍥○:≀⍨≀:∧⍩∨:".split(s)[1][:3-len(s)] Try it online!
• 144k

### Take that frown and turn it around

JavaScript (ES6), 108 107 bytes s=>(S="⊢▷⋆∘○≀∧⍡⍢⍣⍤⍥⍨⍩⊣◁⋆∘○≀∨")[S.search(s[1]||s)+7]+(s[1]?'':':') Demo ...
• 188k

### What have we got?

JavaScript (ES6),  145 ... 138  136 bytes Returns $0$ for dyadic dops, $1$ for monadic dops, $2$ for dfns and $3$ for other. ...
• 188k

### Ken Iverson’s Favourite APL Expression?

APL (Dyalog Unicode), 7 bytes +∘⌽⍨0,⊢ Try it online! Prepend a zero, and add the mirrored array: ...
• 73.8k

### Ken Iverson’s Favourite APL Expression?

Python 2, 34 bytes lambda l:map(sum,zip(l+[0],[0]+l)) Try it online! 37 bytes lambda l:map(int.__add__,l+[0],[0]+l) Try it ...
• 144k
Accepted

### Official Dyalog APL 2016 Year Game

Jelly, 686 bytes ...
• 68.1k

### Official Dyalog APL 2016 Year Game

J, 1041 ... 838 bytes 981 961 952 860 859 I got a little lazy to the end, but it should be more fixed than less. I don't think I'll ever overtake Hexagony, but you never know! beating hexagony! ...
• 39.9k

### Clearly parenthesize APL trains

APL (Dyalog Classic), 71 68 65 63 bytes 0{⍵≡⍕⍵:⍵⋄⍬≡⍵:'⍬'⋄1=≢⍵:⍺∇⊃⍵⋄3≥≢⍵:⍺⌽')(',⍣⍺∊1∇¨⍵⋄⍺∇¯3(↓,∘⊂1∇↑)⍵}⍎ Try it online! The characters I chose for I/O are ...
• 15.2k

### Implement 1-dimensional version of Multi-Take

APL (Dyalog Unicode), 58 50 bytes {{2⊃{⍵[⍒⍴¨⍵]}(⍺,⍵)A⍺(⍵,⍺↓⍨≢A)}/((⌈/,⌊/)0,⍵)↑¨⊂A←⎕} Try it online! What better way to implement this than in APL itself? That ...
• 16.2k

### What valence does this APL train have?

APL (Dyalog Unicode), 59 bytes (SBCS) Anonymous tacit prefix function. Returns [] if invalid, [[]] if dyadic, ...
• 29.9k

### Ken Iverson’s Favourite APL Expression?

Jelly, 2 bytes Ż+ A monadic Link accepting a list of integers which yields a list of integers. Try it online! How? Pretty simple in Jelly to go with the method ...
• 104k

### Floor of complex number

J, 32 31 26 bytes j.&<.+((1<:+)*0j1^<)&(1|]) Try it online! -5 thanks to Razetime for pointing out I could take real and imag parts as left and ...
• 33k

### Evaluation order of an APL n-train

J, 14 bytes [:\:0 _2#:i.@- Try it online! Alternative solution that makes use of divmod with negative divisor. How it works Example using ...
• 73.8k

### Tips for golfing in APL

Indexing modulo vector length ⊃i⌽a is often shorter than the naive ⊃a[(≢a)|i] or a⊃⍨i|⍨≢a (...
• 15.2k

### Tips for golfing in APL

Generate A001057, A130472, and many variations A001057 is a simple sequence of alternating integers, starting with 0, 1, -1, 2, -2, 3, -3, .... A130472 is its ...
• 73.8k

### Official Dyalog APL 2016 Year Game

Dyalog APL (This is a joke, please don't submit), 25,957 bytes. 2016⊢≢⍬ 2016⊢(⊢+≢)≢⍬ 2016⊢(⊢+≢)(⊢+≢)≢⍬ ... Yeah, this is a joke entry, we need an APL solution, ...
• 6,092

### Official Dyalog APL 2016 Year Game

JavaScript (ES7), 836 bytes Everything should work in any browser except 81, 88, and 97, which use the new ** operator. Mostly everything here was done by hand. I'...
• 49.9k

### Official Dyalog APL 2016 Year Game

JavaScript, 1021 bytes Fixed and saved two bytes thanks to Charlie Wynn and ETHProductions. ...
• 5,119

### Ken Iverson’s Favourite APL Expression?

05AB1E, 5 4 bytes 0šÂ+ Try it online or verify all test cases. Or alternatively: 0š+Ć -1 byte thanks to @ovs. Try it online or ...
• 123k

### Ken Iverson’s Favourite APL Expression?

Factor, 27 bytes [ 0 suffix dup reverse v+ ] Try it online!
• 21k

### Floor of complex number

R, 55 bytes function(x,y=x%%1)(x+(sum(y)>1)*c(z<-diff(y)<0,!z))%/%1 Try it online! Straightforward implementation of McDonnell's function. R, 71 bytes <...
• 34.6k

### What have we got?

Jelly,  50 48 46  45 bytes Ỵµṣ”'m2Kṣ”#Ḣ)KµċⱮƤØ{IF©<-oµ⁾waż¤ẇ€‘Ḅ«5×®¬Ḅ⁼1¤ A monadic Link accepting a list of characters which yields: ...
• 104k