Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Code-golf is a competition to solve a particular problem in the fewest bytes of source code.
4
votes
Smooth as Teflon
Python 3, 196 bytes
n=int(input())
p=print
s=' '
def m(i,f,b,c=s):p(s*(n-i)+f+c*(n+2*i)+b)
p(s*n+s+'_'*n)
for i in range(n):m(i,*'/\\')
p('{'+s*n*3+'}'+'='*(n+3)+'0')
for i in range(n-1,0,-1):m(i,* …
1
vote
Make all the squares explode
JavaScript (ES6), 271 259 250 245 bytes
m=>{for(l=m.length;I=J=Q=-1;){for(i=0;i<l;i++)for(j=0;j<l;j++)!((q=m[i][j]**.5)%1)&&q>Q&&(I=i,J=j,Q=q);if(I<0)break;d=[[I-1,J],[I+1,J],[I,J-1],[I,J+1]];D=d.map …