Skip to main content
Share Your Experience: Take the 2024 Developer Survey
3 votes

Apply gravity to this matrix

Minecraft, 0 bytes This is a bit cheaty, but the question does state you can take input in "all reasonable forms" and a grid of Minecraft blocks seems reasonable enough. Input is given as a ...
LostXOR's user avatar
  • 877
2 votes

String with the smallest sum of ASCII values

Ruby, 19 bytes ->x{x.min_by &:sum} Try it online!
G B's user avatar
  • 22.1k
1 vote

Weave two lists, cycling if necessary

Desmos, 109 bytes a=A.length b=B.length i=[2...2max(a,b+1)] k=floor(i/2)-1 f(A,B)=\{\mod(i,2)=0:A[\mod(k,a)+1],B[\mod(k,b)+1]\} Try It On Desmos! Try It On Desmos! ...
Aiden Chow's user avatar
  • 13.5k
1 vote

What and where is the max?

Arturo, 51 bytes $->x->@[m:<=max a:<=flatten x(index a m)/%size x\0] Try it It feels good to golf in Arturo again. Explained more or less in order of ...
chunes's user avatar
  • 24.3k
1 vote

String with the smallest sum of ASCII values

R, 50 47 bytes -3 bytes by pajonk which.min(Map(\(x)sum(utf8ToInt(x)),scan(,""))) Attempt This Online! This outputs a named vector with the smallest ...
int 21h -- Glory to Ukraine --'s user avatar
1 vote

Apply gravity to this matrix

Perl 5 -lF, 69 bytes $a=0;map$r[$a++]+=$_,@F}{say@$_ for reverse map[map$_-->0|0,@r],1..$. Try it online!
Xcali's user avatar
  • 15.2k
1 vote

Apply gravity to this matrix

Arturo, 59 bytes $=>[f:$->m->map size m\0'i->map m'r->r\[i-1]f map f&=>sort] Try it!
chunes's user avatar
  • 24.3k
1 vote

I'm Lazy*: Top-left align my text

Nibbles, 10 nibbles (5 bytes) `'.`';@|$$ Attempt This Online! Explanation It turns out that Nibbles' builtins are a very good fit for this challenge. ...
DLosc's user avatar
  • 39.7k
1 vote

The Game of Cat And Mice | With Matrices

Python3, 287 bytes ...
Ajax1234's user avatar
  • 7,231
1 vote

How secure are my locks?

JavaScript (Node.js), 102 bytes ...
l4m2's user avatar
  • 24.4k
1 vote

Xorting an array

R, 123 112 bytes -11 bytes thanks to @pajonk ...
int 21h -- Glory to Ukraine --'s user avatar

Only top scored, non community-wiki answers of a minimum length are eligible