@Maltysen I think saying that the green check mark is just 15 rep is disingenuous. It's that, plus the claim that the answer beats all the others, plus the permanent top spot no matter the rep, plus the extra upvotes that come from being on top.
@xnor I'm not sure disingenuous is the right word, since I don't have evidence to suggest that Maltysen was being deliberately misleading, but I definitely agree that the tick mark makes much more difference than might be expected.
(starred anyway since Maltysen's name doesn't show up on the starboard and it's a very good point)
Background / Description
Note: for this challenge we will ignore the space that encloses the GitHub avatars
The default GitHub avatar is a 5x5-pixel image. A color is picked randomly, and then random pixels are filled in on one side (right or left, 2x5 size) using that color. Then that side is ...
Should questions (code-golf) include an algorithm used to find the answer in its description? I feel like that whole point of code-golf is to come up with your own algorithm of solving a problem, something shorter-to-write than others, which is the hardest (and most fun part) IMO. If you are give...
@HelkaHomba You should change your name on some other SE site you don't care about to something containing "calvin" and then come in TNB and blow everybodies minds for a couple minutes.
isqrt=0
n=0
o=1
imin = 1
while n<10000:
n = o
isqrt += 1
o = n + (isqrt<<1) + 1
for i in range(n-1,o-1):
m = min(range(1,isqrt+2),key=lambda x:abs(1+i/x-x)+(1+i/x)*x)
p = m/(isqrt+0.)
if p<imin:
print i+1,m,p
imin = p
A Faro shuffle is a technique frequently used by magicians to "shuffle" a deck. To perform a Faro shuffle you first cut the deck into 2 equal halves then you interleave the two halves. For example
[1 2 3 4 5 6 7 8]
Faro shuffled is
[1 5 2 6 3 7 4 8]
This can be repeated any number of times...
Challenge
In the shortest amount of code:
Compute the length of the permutation cycle of a perfect shuffle on a deck of cards of any size n (where n ≥ 2 and n is even).
Output a table of all cycle lengths for 2 ≤ n ≤ 1000 (n even).
Note that there are two basic ways of defining a perfect shu...
Aw, come on. Now since the inner recursive macro is terminating, it's also terminating the outer macro, which means 100@r does the same thing as @r. :/
vim, 63
Oma50%mb:norm@q<cr>gg<esc>vgg"rcjdd'apjma'b@q<esc>0"qDdd<C-a>AA@r<C-v><esc><esc>0D@"xxdd@"
Wow. This is possibly the hackiest thing I've written for PPCG, and that's saying something.
Input is taken as N on the first line followed by the elements of the array, each on its own line.
O...
@Fatalize Well I would't say I've finished Cheddar. More of I've just reached a v0.1-alpha version of Cheddar. As soon as I make it turing complete (add fors) I'll make the first release
@Fatalize Making a language like Cheddar is a rather large project so I decided to choose a language I am very familiar with, which is JS. If I chose Python or something, I'd be spending too much time googling how to do things in it, whereas in JS I really only have to think about the functionality, rather than the syntax, etc.
@Fatalize As in, Cheddar uses a blend of syntax from various popular language to make it very familiar to most people. Additionally, it is very compliant so when coding in Cheddar, meaning you can focus on the actual workings of the code, rather than figuring out how the language works
Stack Overflow is no longer the place for code-golf challenges. However, those that were asked and answered here on Stack Overflow are part of our history, not to mention very, very interesting.
The historical lock was created for this purpose; to preserve historical, off-topic questions. And it...
And I'm not convinced that, in the year since Shog added the locks, that there are any deleted questions remaining that are worthy of undeletion and locking.
Anonymous
You're claiming that code golf questions got deleted after Shog added the locks to all the >=10 ones. That doesn't make sense, because the MSO question states that all of the code golf questions got deleted. If what you're saying is true, then one of the locked questions must have gotten re-deleted, in which case there's probably a good reason for it.
Description
In a city called "Stalls City", every tourist who visit will be given a unique code based on the figures of the tourist favorite. When a tourist favorite number is already used as a unique code, then the tourists will be given a unique code with the smallest value that is not used an...
Light black box: generate mirror processors
code-challenge
[ WORK IN PROGRESS - LOTS OF OUTSTANDING QUESTIONS ]
Input
The list of black box output values for all black box input values from 0 to 255 (inclusive), in any reasonable format. Each value is also in the range 0 to 255.
Output
A...
Last time when I tried to chase a dog, it thought I was playing with him. The dog was turning back and staring at me when I suddenly stopped running..lol
The easiest way to catch a non-scared dog is to jump, crouch, then run up to the dog and back to where you want the dog to be. They think you're playing, and follow. A scared dog however...
@JeffTeoh Hrm, sorry. I haven't done any smoke in Blender, so I have no idea how to help you. If I had the .blend, I'd just fiddle around and google questions.