Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »

Posts by Shaggy‭

109 posts
66%
+2 −0
Challenges Multiply two strings

Japt -m, 5 bytes Takes input in reverse order. Sadly, Japt has no minimum built-in for strings. VcmUc Try it VcmUc :Implicit map of each U in the first input string V :Second inp...

posted 2y ago by Shaggy‭  ·  edited 2y ago by Shaggy‭

Answer
60%
+1 −0
Challenges 99 Shortened Bottles of Beer

JavaScript (V8), 185 bytes for(c=99;c;)print((f=(s=` on the wall`)=>`${c||99} bottle${~-c?`s`:``} of beer`+s)()+`, ${f``}. ${--c?`Take one down and pass it around`:`Go to the store and buy s...

posted 2y ago by Shaggy‭

Answer
71%
+3 −0
Challenges Generate Lewis Caroll's Jabberwocky

Japt, 610 606 bytes Don't think there's anything more that can be done with it than this. 933î`'T°s ߍ¦g, „d e sҐy ‘vƒ Did gyœ „d g‹½e ˆ e °¼; A¥ Úßy ØÀ e ޒgovƒ, A˜ e Ú  ÎÈs ŒtgŸ¼.0"BeØ ...

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges Small integer swapping

Japt, 3 bytes I/O as an array. cUé Try it cUé :Implicit input of array U c :Concatenate Ué : U rotated right once

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
84%
+9 −0
Challenges Coat of Many Colours

Challenge Given a list of unique colour names as input, sort them in the order that they first appear in Joseph's Amazing Technicolour Dreamcoat. Example Input: green, blue, red, brown Outpu...

6 answers  ·  posted 3y ago by Shaggy‭  ·  last activity 2y ago by radarek‭

66%
+2 −0
Challenges Juggler sequences

Japt, 17 bytes Needs some more work. É?[U]cßÂUp½+Uu:1ì Try it If there's a proof that the length of the sequence for any given n never exceeds n**3 then ... Japt, 14 bytes NcU³Æ=Âp½+UuÃâ ...

posted 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Juggler sequences

JavaScript, 37 32 bytes Outputs a comma delimited string. f=n=>n-1?n+[,f(n**(.5+n%2)|0)]:n Try it online!

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges Getting perfect squares, differently

JavaScript (V8), 28 bytes for(x=y=0;;++y)print(x+=++y) Try it online!

posted 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges Getting perfect squares, differently

Japt, 9 bytes No infinite lists in Japt so we'll have to go with a recursive solution. ßOpTµJJµ2 Test it ßOpTµJJµ2 ß :Recursive call with (irrelevant) argument Op : ...

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
71%
+3 −0
Challenges Are All Elements Equal?

Rockstar, 76 bytes Takes individual integers as input. listen to f let n be f o's1 while n let o be o and n is f listen to n say o Try it (Code and input will need to be added manually...

posted 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Are All Elements Equal?

JavaScript, 20 bytes Outputs false for truthy and true for falsey. a=>a.some(x=>x-a[0]) Try it online! Outputs true and false as normal. a=>new Set(a).size<2 Try it online!

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
75%
+4 −0
Challenges Are All Elements Equal?

Japt, 3 bytes e¡g Try it e¡g :Implicit input of array U e :Is equal to ¡ :Map U g : First element of U

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Reduce over the range [1..n]

JavaScript, 25 bytes The function is called with f(g)(n), where g is a function. g=>h=n=>n-1?g(h(n-1),n):1 Try it online!

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Reduce over the range [1..n]

Japt, 4 bytes Takes the operator as a string but would also work without modification using a function by assigning it to variable V. That can be done in the header by leaving a blank line and the...

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges Guess the language! (Cops' Thread)

Jelly, cracked by m90 13 bytes Should be pretty simple - I'm running out of ideas; one of the downsides of only golfing in 2 languages! “¿×⁶ṆḶN{N=ȷṾ» Try it online!

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges Guess the language! (Cops' Thread)

brainfuck, cracked by Aaron Miller, 243 bytes void main(x,y)->{ printf=io.write(z=x-y); printf("+++++[++++>---<]>.+[--->+<]>+++.+.+++.+[---->+<]>+++.[->+++<]&...

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges 99 Shortened Bottles of Beer

Japt, 117 116 115 bytes Needs more golfing or, perhaps, a completely different approach. Borrows a couple of tricks trick from ETHProductions' original version. Includes 2 trailing newlines. ´LÇ...

posted 3y ago by Shaggy‭  ·  edited 2y ago by Shaggy‭

Answer
85%
+10 −0
Challenges It's Hip to be Square

Challenge A catalogue type challenge that simply asks: Given an integer n (where n>=0) as input return a truthy value if n is a perfect square or a falsey value if not. Rules You may take...

20 answers  ·  posted 3y ago by Shaggy‭  ·  last activity 2y ago by Zakk‭

60%
+1 −0
Challenges Guess the language! (Robbers' Thread)

Cracks Mark Girrafe's answer: PicoLisp A sneaky search of TIO's GitHub org revealed this one ;) (prinl "Cops and Robbers")(bye) Try it online!

posted 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Guess the language! (Cops' Thread)

Rockstar, cracked by Hakerh400, 126 bytes I never thought of languages that would ignore everything except the strings - I should have stated that the solution should be irreducible. Hakerh400 get...

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Guess the language! (Cops' Thread)

JSFuck, cracked by user*, 6106 bytes *With honourable mention to AndrewTheCodeGolfer who first recognised it as JavaScript. This version will only work in Firefox v90+. [][(![]+[])[+!![]]+(!![]+...

posted 3y ago by Shaggy‭  ·  edited 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Guess the language! (Robbers' Thread)

Cracks Mark Girrafe's answer: Rust fn main(){print!("Cops and Robbers")} Try it online!

posted 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Guess the language! (Robbers' Thread)

Cracks Mark Girrafe's answer: F# printfn"Cops and Robbers" Try it online!

posted 3y ago by Shaggy‭

Answer
66%
+2 −0
Challenges Guess the language! (Robbers' Thread)

Cracks Quintec‭'s answer: Canvas My first clue was the echp; if the language used echo then why wouldn't it error on that? The second clue was that the last line contained the exact output we need...

posted 3y ago by Shaggy‭

Answer
60%
+1 −0
Challenges Guess the language! (Robbers' Thread)

Cracks Kevin M. Mansour‭'s answer: Erlang Searched for languages that use fwrite, no joy. Searched for io:fwrite, got it instantly main([])-> io:fwrite("Cops and Robbers"). Try it onli...

posted 3y ago by Shaggy‭

Answer