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 »

Search

Advanced Search Options

To further refine your search, you can use additional qualifiers such as score:>0.5. For example, the search score:>=0.5 created:<1y grammar would return only posts mentioning "grammar" that have a score >= 0.5 and were created less than a year ago.

Further help with searching is available in the help center.

Quick hints: tag:tagname, user:xxx, "exact phrase", post_type:xxx, created:<N{d,w,mo,y}, score:>=0.5

Filters
1.6k posts
 
60%
+1 −0
Challenges Obligatory Quine Challenge

Japt, 9 bytes All credit to ETH on this one. 9îQi"9îQi Test it 9î :Repeat the following to length 9 Q : Quotation mark i"9îQi : Prepend "9îQi" And, for th...

posted 3y ago by Shaggy‭

Answer
60%
+1 −0
Sandbox FizzBuzz based on line count

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

Article code-golf
60%
+1 −0
Challenges Partial Sums of Harmonic Series

JavaScript, 29 bytes f=(n,x=0)=>n>0?f(n-1/++x,x):x Try it online!

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

Answer
60%
+1 −0
Challenges Create a Sudoku

APL (Dyalog Unicode), 22 bytes ⎕←∘.((1+⍳9)⌽⍨⊣+3×⊢)⍨⍳3 Try it online! Requires zero-indexing. ⎕←∘.((1+⍳9)⌽⍨⊣+3×⊢)⍨⍳3 ⍳3 ⍝ Make the range [0, 2] (row and cols of 3×3 box...

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

Answer
60%
+1 −0
Challenges Evens or Odds - you know this one

C (gcc), 20 bytes f(a){puts("!"+a%2);} Try it online! Function solution. Prints ! in case of even numbers, otherwise just new line.

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

Answer
60%
+1 −0
Challenges Obligatory Quine Challenge

h, 4 bytes 1,-1 Neither this program (by VilgotanL) nor the language (by Nerdaxe) are mine, but I think the latter is interesting and so I am submitting the former. Step-by-step guide: Accumu...

posted 3y ago by AndrewTheCodegolfer‭

Answer
60%
+1 −0
Challenges Evens or Odds - you know this one

Ruby, 8 bytes ->n{n%2} Generic mod-in-a-lambda solution. Alternately, for 2.7+: ->{_1%2} Try it online!

posted 3y ago by snail_‭

Answer
60%
+1 −0
Challenges Evens or Odds - you know this one

MAWP, 8 bytes @!2P2WA: Try it! 1 for odd and zero for even. mawp doesn't have modulus, so it floor divides by 2, multiplies by 2 and subtracts from the input.

posted 3y ago by Razetime‭

Answer
60%
+1 −0
Challenges Recreate the Server Fault logo

Make the Server Fault logo using the following criteria: The boxes' measurements: There are 3 columns of 5 boxes, with long ones at the left where the rest are regular. The following measure...

0 answers  ·  posted 3y ago by General Sebast1an‭

60%
+1 −0
Challenges Tile pyramids on top of each other!

C (compliant), 106 bytes char r,i,s[80];void f(int n){memset(s,32,79);for(;r<n;puts(s),r++)for(i=0;i++<n*2;s[n-r-1]=47,s[n+r]=92);} Try it online! Standard C compliant function solutio...

posted 4y ago by Lundin‭

Answer
60%
+1 −0
Challenges Write a Deadfish Interpreter

C (gcc), 153 bytes a,b;f(char*s){for(char*c,*o="idso";*s;s++)for(c=o;*c;c++)*s==*c&&(b=c-o,a+=!b,a-=b==1,b==2?a*=a:0,b==3&&printf("%d%c",a,s[1]?44:10),a==-1|a==256?a=0:0);} Tr...

posted 4y ago by Lundin‭  ·  edited 4y ago by Lundin‭

Answer
60%
+1 −0
Challenges Longest Increasing Subsequence

Japt -h, 12 bytes à kÈäÎdÄÃmÊñ Try it à kÈäÎdÄÃmÊñ :Implicit input of array à :Combinations k :Remove elements that return true È :When pass...

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

Answer
60%
+1 −0
Sandbox C&R: Errored Out

posted 4y ago by Corsaka‭  ·  edited 4y ago by Corsaka‭

60%
+1 −0
Meta Tags for sandbox status. [duplicate]

I suggest we have some status tags for Sandbox. In particular, one like "status-finalized" instead of manually (and therefore inconsistently and not searchable) changing the title to say "[FINALIZE...

0 answers  ·  posted 4y ago by manassehkatz‭  ·  closed as duplicate 4y ago by Quintec‭

Question feature-request
60%
+1 −0
Sandbox Write a Deadfish Interpreter[FINALIZED]

posted 4y ago by Razetime‭  ·  edited 1y ago by trichoplax‭

60%
+1 −0
60%
+1 −0
Challenges Integer to Roman numeral

C (compliant), 197 198 bytes. Golfed version of the function in the question, using X macros: #define L Y(1000,M)Y(900,CM)Y(500,D)Y(400,CD)Y(100,C)Y(90,XC)Y(50,L)Y(40,XL)Y(10,X)Y(9,IX)Y(5,V)Y(4,I...

posted 4y ago by Lundin‭  ·  edited 4y ago by Lundin‭

Answer
60%
+1 −0
Challenges Integer to Roman numeral

Perl 5 -pMRoman, 10 bytes (17 if including command-line switches) $_=Roman$_

posted 4y ago by msh210‭

Answer
60%
+1 −0
Challenges The Camelot Wheel

APL (Dyalog Unicode), 110 67 bytes {(⍕((f⊖⍪'AEBFCGDAEBFD'),r⌽12↑¯6↑5⍴'-')⍳2↑⍵),⎕a⌷⍨1+0≠f←¯3+r←3×'i'∊⍵} -43 bytes from dzaima. Requires input exactly as shown in the diagram. A bit fiddly with...

posted 4y ago by Razetime‭  ·  edited 4y ago by Razetime‭

Answer
60%
+1 −0
Sandbox The Pell Numbers[FINALIZED]

posted 4y ago by Razetime‭  ·  edited 4y ago by Razetime‭

60%
+1 −0
Meta Microcontroller-involving challenges and the rules.

For this to work, I think we need to rule out all start-up code (the C runtime) but also the register maps. So I think answers should be a void main (void){ ... } (or equivalent) function solution ...

posted 4y ago by Lundin‭  ·  edited 4y ago by Lundin‭

Answer
60%
+1 −0
Challenges The Pell Numbers

Haskell, 21 bytes f=0:scanl((+).(*2))1f Try it online!

posted 4y ago by Hakerh400‭

Answer
60%
+1 −0
Challenges Ratio limits of fibonacci-like series

Stax, 5 bytes òP^↓Φ Run and debug it Same idea as Quintec's answer. Input as a floating point number. Explanation 1gpun+ 1 start with 1 gp apply the following till a fixpoint...

posted 4y ago by Razetime‭  ·  edited 4y ago by Razetime‭

Answer
60%
+1 −0
Q&A Tips for golfing in Scala

What general tips do you have for golfing in Scala? I'm looking for ideas that can be applied to code golf problems in general that are at least somewhat specific to Scala (e.g. "remove comments" i...

1 answer  ·  posted 3y ago by user‭  ·  edited 3y ago by user‭

Question code-golf tips
60%
+1 −0
Q&A Tips for golfing in Scala

Making a function with val can be shorter than with a def If you're pattern matching, you can use Scala's special syntax and omit match when assigning an anonymous function to a val. As you can se...

posted 3y ago by user‭

Answer