# Questions tagged [popularity-contest]

A popularity-contest is a competition where the answer with the highest vote tally (upvotes minus downvotes) wins. As these are frequently closed, read the tag info and post your challenge to the sandbox first.

396 questions
Filter by
Sorted by
Tagged with
461 views

### (Σ*)² ⟲ Σ* (aka Round-Trip a String Pair) [closed]

This is a challenge I thought of recently which I think is not hard but allows for a wide range of possible solutions. Seems like a perfect fit for the creativity of PPCG users :) Your Task Define two ...
305 views

1k views

### Output a unique sign sequence

A sign sequence is an infinite sequence consisting entirely of $1$ and $-1$. These can be constructed a number of ways, for example: Alternating signs: $1, -1, 1, -1, ...$ $-1$ for primes, \\$...
123 views

### Look for n-plicates [closed]

If you are given an array of numbers between 1 and 100 and an integer n, you must remove any instances of an item that appear greater than ...
3k views

### Make The Finest Magic Code Square

In math a magic square is an N×N grid of numbers from 1 to N2 such that every row, column, and diagonal sums to the same total. For example here's a 3×3 magic square: In this challenge we'...
235 views

### Heart-shaped quine [closed]

As you may or may not know, Valentine's day is getting close. So today, my task for you is: Write a heart-shaped quine Rules: Code should look like an identifyable heart shape, i.e. Has two round ...
350 views

### Nested lists as printable 2D objects [closed]

I don't know if something like this exists already (and I'm not finding the right key words) but if not, it felt like it could be an interesting coding puzzle. The challenge is, to take an ...
434 views

### Polycops and Robbers (Robbers' Thread)

This is the robbers' thread, the cops' thread is here A polyglot is a program, that without modification, can run in multiple languages. Robbers' Challenge First, find a vulnerable cop's answer, ...
1k views

### Polycops and Robbers (Cops' Thread)

This is the cops' thread, the robbers' thread is here A polyglot is a program, that without modification, can run in multiple languages. Allowed languages Any language that was made before the ...
378 views

### Escape from the tarpit (Robbers)

This is a cops-and-robbers challenge based around defining languages and proving they are Turing complete. This is the robbers' thread. The cops' thread is here. Robbers The cops will post definitions ...
695 views

### Escape from the tarpit (Cops)

This is a cops-and-robbers challenge based around defining languages and proving they are Turing complete. This is the cops' thread. The robbers' thread is here. Cops As a cop, you will prepare two ...
2k views

### Design a One Instruction Set Computer! [closed]

Notice: I'm willing to give a bounty to any answer that I find interesting. Your challenge is to design a Turing-complete one instruction set computer (OISC): An OISC is an abstract machine that ...
1k views

### Lorem Ipsum Generator [closed]

Lorem Ipsum is placeholder text used when preparing layout without wanted to have content already filled. One of its key features over using some arbitrary text is that it is nonsense. It isn't even ...
6k views

### Print a Variable's Name [closed]

Write a function (not a full program), so that if the function is called with a single global variable (or your language's closest equivalent) as its argument, it outputs (i.e. prints or returns) the ...
4k views

### Reversed language name [closed]

You should code a piece of code that looks like it outputs the language name but actually outputs the name reversed. E.g. a Python program should look like it outputs ...
3k views

### April Fools Day! [closed]

Your challenge is simple: write a program or function which appears to print the first ten numbers of any integer sequence (on OEIS, the answerer may choose which sequence), but instead prints the ...
5k views

### Write a Programming language of Unknown Completeness

Determining whether a Language is Turing Complete is very important when designing a language. It is a also a pretty difficult task for a lot of esoteric programming languages to begin with, but lets ...
604 views

### HRNG - Human Random Number Generator [closed]

You know it: keyboard or mouse input is just too mainstream to create Random Numbers through human behavior. Create the most unique (Pseudo)Random Number Generator that create its numbers through ...
349 views

### A boring version of yourself [duplicate]

A boring version of yourself Have you ever dreamed of a boring version of you which types the text you just typed ? No ? Because that's exactly what I'm challenging you to do ! The program needs to ...
342 views

### Unpixellate an image [closed]

When you resize an image down to a very small size, it looks very blocky when you scale the pixels back up individually. In extreme cases, as above, you can no longer reconstruct the original image, ...
436 views

### Help Me Count to Ten! [closed]

You will write a simple program that prints exactly 1 2 3 4 5 6 7 8 9 10 to STDOUT, Console, or your language's closest output method. No other visible output ...
2k views

### 8 ought to become Infinity [closed]

Let's take a look on a typical loop, which usually performs 8 iterations: for (int x=0; x<8; ++x); You have to make it infinite! It's a popularity-contest ...
174 views

### Correlation Coefficient of Words [closed]

This is going to be relatively quick... Challenge Given a lower-case word as input, calculate the Pearson's Correlation Coefficient between the letter position of the word (nth letter within the ...
222 views

### Generate groups for in-class work [closed]

In a smallish class, some lectures are set aside for working in groups. The instructors don't want people to group themselves together with the same people every time; instead, they create the groups ...
2k views

### Patch the Paragraph

In the spirit of Patch the Image, here's a similar challenge but with text. Challenge Bit rot has afflicted your precious text! Given a paragraph composed of ASCII characters, with a rectangular ...
290 views

### Meta Obfuscate a String [closed]

There are numerous reasons for trying to obfuscate input. These include preventing decompiling, and being a nuiscance. With this in mind your challenge should your choose to accept it is to write a ...
2k views

### Computer Generated Cracked Soil

Write a program that takes in an integer from 0 to 65535 (216-1) and generates a unique 500×500 pixel image that looks as similar as possible to these 6 real life images of cracked soil: These ...
5k views

### Deep learning Fizzbuzz [closed]

Inspired by the job-interview with Joel Grus, the goal of this challenge is to write a tensorflow (or other deep/machine learning) program that learns Fizzbuzz and correctly prints out the answers to ...
225 views

### Ponderous primality testing [closed]

One of my favorite algorithms was posted on Stack Overflow as an answer to What is the fastest way to generate prime number recursively?. In pseudocode: Nathan's algorithm ...
323 views

### What time is it again? [closed]

The Inspiration The Challenge I'm tired of seeing the same old-same old clock in my top-right-hand corner of my screen. It's time for a new clock. While the clock clock sated my lack of interesting ...
8k views

### Patch the Image

In a popular image editing software there is a feature, that patches (The term used in image processing is inpainting as @mınxomaτ pointed out.) a selected area of an image, based on the information ...
279 views

### Find the line guaranteed by Sylvester-Gallai

The Sylvester-Gallai theorem says: Suppose you have a finite list of points in the plane. Suppose further that not all of those points are collinear (lie in a single line). Then there is some line ...
239 views

### Unique multiplication by ten [closed]

People, it's a popularity contest, you have to do somthing cool here. Think about cool ways of breaking the code in most languages, not about validating for everyting! Initially this challenge ...
2k views

### Paint by Numbers (using programming, not numbers)

Your task is to create a program which takes a black-and-white outlined image (example images are below) and fills it in with colour. It is up to you how you section off each region and which colour ...
4k views

### Make the pattern from composition notebooks [closed]

This challenge was xnor's idea, taken from Digital Trauma's challenge donation thread. Your challenge is to write a program that, as xnor put it, "procedurally generate[s] the splotchy black-and-...
306 views

### Build an image-glitching algorithm [closed]

It's well known that corrupted JPEG files or NTSC/PAL streams will appear as distorted versions of the true images, or versions covered in random-looking blocks of pixels. Consider the below image (...
326 views

### Most creative/diabolical/entertaining way to find Python version? [closed]

There are important differences between Python 2 and 3, so it's often useful to know which version of the interpreter is running your code. The straightforward method is something like this: ...
443 views

### Self-debugging code [closed]

Your Task Write a program using ASCII characters. Five alphanumeric (0-9, A-Z, a-z) characters will be inserted at random into your program's source code. Your task is to detect and output these ...
475 views

### Generate 0 or 1 [closed]

Is this Q too easy to ask, or has it just never been thought of? Generate a random number, either 0 or 1 using a program You may use a pre-defined function. The code must be executable. (It can't ...
3k views

### Create a programming language that only appears to be unusable (Robbers' thread)

See the cop thread for more information. Each answer to this question should crack an answer there. That is to say, it should be code to find the third-largest integer in the input when run in the ...
10k views

### Create a programming language that only appears to be unusable

Robbers' challenge thread is here. Cops' challenge: Design a programming language that appears to be unusable for programming, but admits computation (or at least completion of the task) through some ...
587 views

### Programming? No, it's Projamming [closed]

Hopefully not duplicate, but I did not find one. Challenge The challenge is to write full program, which compiles (without errors), but, when executed, will not finish the execution till the end, ...
36k views

Try to write some code in your language and make it not satisfying our criteria of being a programming language any more. A language satisfies our criteria (simplified version for this challenge) of ...
265 views

### Help me get a date for Homecoming [duplicate]

My school has its Homecoming dance next week, and there's someone in mind I want to ask. But I don't want to ask her the normal way. I want to send her a program that prints "Rachel, will you go to ...
2k views

### RTTTL Obfuscation

RTTTL, or Ring Tone Text Transfer Language is a music format that was invented by Nokia in the dawn of time when dinosaurs roamed the land. It allows for fairly crude pieces of music (no chords or ...
894 views

### How many languages can you use simultaneously in ONE functioning program in under 500 bytes [closed]

Intro In Objective-C (a superset of C and an object-oriented language), I can create an object called a ...
182 views

### Self-validating quine [closed]

Quines have been around forever. It's a fun challenge: write a program that, when executed, generates its own source code as output. But how do you know it's actually producing its own source code? ...
183 views

### Palandrome-ish code [closed]

Create a program that does the same thing forwards and backwards, in different languages. “Different languages” does not include different versions of the same language. Challenge This program can ...