instruction stringlengths 34 53.1k |
|---|
inspired by this blog: http://alstatr.blogspot.co.uk/2014/02/r-animating-2d-and-3d-plots.html I made a 2D gif of a heart with:
library(animation)
saveGIF({
for(i in 1:150){
dat<- data.frame(t=seq(0, 2*pi, by=0.1) )
xhrt <- function(t) 16*sin(t)^3
yhrt <- function(t) 13*cos(t)-5*cos(2*t)-2*cos(3*t)-cos(4*t)
dat$y=yhrt... |
The Walsh matrix is an interesting fractal matrix with the property that every single value in a Walsh matrix has a value of either -1 or 1. Additionally, the size of a Walsh matrix is always a power of 2.
Because each Walsh matrix is identical to the top-left quarter of the immediately higher-order Walsh matrix, we ca... |
Objective:
The task is to create a chatbot with whom you can spend your time discussing your deepest thoughts with. Create a chatbot with an AI that learns from your input. Your bot should inspire you to releave your darkest inner truths.
Inspiration:
http://en.wikipedia.org/wiki/Chatterbot
http://io9.com/5901579/10... |
Write a program or function in any language that tells if the input is a prime number.
The input is a string representing a natural number in base-10.
The output is one of the two strings "Prime" or "Not!!" which correctly identifies the input.
Arithmetic operators, bit-wise operators, numeric variables and constants,... |
Your program must find all the words in this wordlist that contain all the vowels (a e i o u y). There are easy ways to do this, but I am looking for the shortest answer. I will take any language, but I'd like to see Bash.
Here is an example (could be much improved):
cat wordlist.txt | grep "a" | grep "e" | grep "i" | ... |
The task:
Build a calculator that takes a simple math equation in Chinese and outputs the correct answer(To the equation from the users input) in Chinese.
Scope:
Any programming language can be used.
Input must be in Chinese otherwise an error message will be displayed .
Output must be in Chinese.
Only input and outp... |
Rules (not too restrictive; flexible):
1.Must be able to draw shapes on command (e.g., I type in "square" and a square is drawn).
Minimum completed shapes that can be drawn on command: Square, Circle, Triangle, Pentagon.
2.Must also be able to also draw shapes vertex-by-vertex, specified by a command function that give... |
Write some code in any language that inputs a string such as "Today is a great day" (Note that there is no punctuation) and converts it to the "Secret Language". Here are the rules for the "Secret Language".
a=c, b=d, c=e and so on (y=a and z=b)
separate each word by a space
make sure there is proper capitalization
E... |
Background:
You have been given an assignment to convert base 10 numbers to base 2 without using any premade base conversion functions. You can't use any imported libraries either.
Problem:
Convert an input string from base 10 (decimal) to base 2 (binary). You may not use any premade base conversion code/functions/me... |
Problem:
Your goal is to add two input numbers without using any of the following math operators: +,-,*,/.
Additionally, you can't use any built-in functions that are designed to replace those math operators.
Scoring:
Smallest code (in number of bytes) wins.
Update
Most of the programs i've seen either concatenate two... |
Being a big fan of the Rubik's cube and of cool art, I've been working on combining the two together to do some really cool stuff. Basically solving miniature Rubik's cubes to form rudimentary pixels in the formation of Rubik's cube art. Examples of such art can be seen via this link: http://google.com/search?q=rubik%2... |
The challenge
Make a JavaScript program that can use a HTML table as a canvas, having each cell a pixel.
You can either input the position and color values in a form or by using the console.
Score calculation
+10 points for not using JQuery
+15 points for the cells scaling equally to keep the same table aspect ratio w... |
Task
Create a program that calculates the factorial of a number using no built-in factorial functions. Easy? The catch is that you must write your entire program (including testing it) in haiku form.
You can use as many haikus as you need, but when pronounced, they must follow the 5-7-5 syllable format.
Scoring
This i... |
As a programmer you certainly know the error of a stack overflow due to an obvious recursion.
But there are certainly many weird and unusual ways to get your favourite language to spit that error out.
Objectives:
Must cause a stack overflow which is clearly visible on the error output.
Not allowed to use an obvious ... |
Your job is to draw a Bézier curve given it's control points. The only criteria is that you actually have to show how to draw the curve from the initial control point to the last one.
Criterias
The result has to be animated, e.g. it has to show the drawing process somehow. The way you do the animation is irrelevant, i... |
There’s already been a question about simulating the Monty Hall Problem. This one is different. The user will play the Monty Hall Problem. Your program will play the role of the host. Montybot, if you like.
Here are the steps:
Pick (randomly) which of the three doors hides the prize.
Output a visual display of three... |
Introduction
There are lots of utilities out there capable of creating a high CPU load to stress-test your processor(s). On Microsoft Windows, you can even use the on-board calculator.exe, enter a large number like 999999999, and press n! several times to make your CPU(s) work overtime.
But what’s in a solution if you ... |
Your program has to print out a number of spaces, followed by a dot and a newline.
The number of spaces is the x position of your dot defined with 0 < x < 30
Every new line is a turn. Your program runs for 30 turns. Your program starts with a random x position and every turn shifts this position randomly by 1 to the le... |
You have to write a program, implementing a function digitsum(int i). The program has to modify its own code (for languages, where this is not possible with f.e. reflection, please be creative) to get itself to solve the goal.
You start with
function digitsum(int i){
return i;
}
and implement an evolutionary algo... |
Happy birthday to Me!
Write a program that prints Happy birthday to me! on its birthday.
The program's birthday is the creation, last modification or compilation time of the program (you choose), and must not be hard-coded.
The date you use as the birthday must not be affected by the program's invocation or execution ... |
This is a very crude text encoding algorithm I came up with the other day. It won't work if the text has more than 256 different characters in it – but it does support Unicode, at least in my Python implementation.
The algorithm:
Find all the unique characters in the text. Let's call this list, unique-chars.
Break the... |
Your challenge is to take some source code as input, and output which programming language it is written in.
For example, you could have the input
class A{public static void main(String[]a){System.out.println("Hello, World!");}}
And output
Java
Your two main goals are diversity (how many programming languages you can... |
Goal
Write a function or program sort an array of integers in descending order by the number of 1's present in their binary representation. No secondary sort condition is necessary.
Example sorted list
(using 16-bit integers)
Dec Bin 1's
16375 0011111111110111 13
15342 00111011111011... |
Problem:
You are making a new phone where people can type in specialized phone numbers, for example, 1-800-program, and they would be converted automatically to a usable phone number, like 1-800-7764726 (for the previous example).
Your program will recieve a string if any length with numbers, letters and dashes, and c... |
Your task – if you choose to accept it – is to have your program print, literally, either one of the following:
E=mc² (if your language supports Unicode (so no HTML trickery, for instance))
E=mc^2 (if your language doesn't support Unicode)
Here are the conditions:
Your program must consist of exactly two expressions... |
Write the shortest program to solve a quartic equation.
A quartic equation is a polynomial equation of the form:
\$ax^4 + bx^3 + cx^2 + dx + e=0\$
A solution for \$x\$ is a number such that the above evaluates to 0.
Rules
The program must take in the 5 floating point coefficients of the equation \$ax^4+bx^3+cx^2+dx+e... |
Inspired by http://xkcd.com/1331/
In this xkcd comic, there are several gifs that all blink with different frequency. I want to know what the period would be if was all a single GIF. Given a list of numbers representing the individual frequencies, output the period of the overall GIF.
Formal Definition
Input:
N
f1
f2
.... |
You are to post an answer you posted that exploited a loophole in the challengers question. Bonus points if it caused them to rewrite the question.
For example, one challenge was to write a program that such that if a random character is removed, it still works, and your score is how many characters it fails on. Some o... |
Problem:
You must make a program that does the following:
takes a large string of lowercase text, and counts all the occurrences of each letter.
then you put the letters in order from greatest to least occurences.
then you take that list and turns it into an encoder/decoder for the text.
then encodes the text with tha... |
The Oscars are coming up soon and we all know who's going to win Best Actor in a Leading Role this year right? The great Leonardo DiCaprio of course! Despite his superb performances in all of his films during his career, he has yet to win an Academy Award. So as tribute and as a way to wish him luck during the Awards C... |
This is an "arrow maze":
v <
> v
> ^
> v
^ < *
The * marks the spot where you will finish. Your goal is to find where the maze starts (hence, reverse maze). In this case, it's the first > on the second line.
v------<
S-+---v |
| >--^
>-+-------v
^ < *
Note that al... |
Your task – should you choose to accept it – is to build a program that parses and evaluates a string (from left to right and of arbitrary length) of tokens that give directions – either left or right. Here are the four possible tokens and their meanings:
> go right one single step
< go left one single step
-> go rig... |
The contest is to make a program or function that takes an arbitrary string
resembling source code and checks to see if the "braces" follow the basic rules for
brace matching. That is, the number of left braces and right braces have to match, and you
can't have a right brace without a corresponding prior left brace.
Yo... |
Write a program that takes a sorted integer array, shuffles all the elements in such a way that for every i there must exist a j such that, one of the following is satisfied:
a[i] < a[j] < a[i+1]
a[i] > a[j] > a[i+1]
i and j are within the bounds of array.
If there are not many distinct elements, you must show an err... |
Problem:
Generate a sentence that can be read and understood. It must contain a subject, verb, and object, and tenses and plurals must match. The program must also be able to generate several different sentences to qualify.
Rules:
Hard-coding the sentences is not permitted, and nor is reading them directly from a file... |
Your challenge here is to draw a trololologram.
You can choose any language.
The answer with more upvotes and the one that exploits more holes wins.
Rules for valid answers:
You can't use any network resource or external file (except the source-code)
You can't post someone else's answer
You can't have it stored in any... |
Your task is to take an input string of ascii characters and output the string as a series of vertical words separated by spaces. An example is shown below:
Given the string:
Hello, World! My name is Foo.
the output should be:
H W M n i F
e o y a s o
l r m o
l l e .
o d
, !
10 bonus points will be awarded if ... |
Write a program that starts itself again when finishes.
There should be no more than one instance of the program running at same time. Not even for a slightest moment of time.
You can ignore any instance that is manually started by user during your cycle. But your code should not do it in your restart cycle.
Progra... |
Here's a fun idea:
Write a simple game (tic-tac-toe, guess the number, etc) that has an easter egg in it, that can be triggered by a specific, special input from the user and does something cool, but the code for the game does not appear to contain any easter eggs (or any obviously obfuscated code) at first glance.
Thi... |
Your task - if you accept it - is to write a program which helps understanding my proposal on meta by calculating the winner of a code-golf-reversed competition. Of course, answers to this question will be treated as proposed, so your program (if correct) can calculate whether your answer will become the accepted answe... |
Your program will receive an ascii shape consisting of only underscores _, pipes |, spaces and newlines \n, which, together, represent a horizontally-aligned, right-angled shape. Together with this shape, on a new line, you will also receive either a positive or a negative integer, whose absolute value will be either ... |
There are some ways which cause an endless high CPU usage such as catching recursion exception. e.g. the following script in Python causes that problem:
def main():
try:
main()
except:
main()
main()
This is an obvious and simple example, but there might be some strange ways to arise such probl... |
In bash, this code posts String to post to http://www.example.com/target:
curl -d "String to post" "http://www.example.com/target"
NOTE: You should use http://www.example.com/target as the URL to POST to, without any change.
I think all other languages that I have knowledge in need a lot more code than this. I'm not b... |
The goal of this code golf is to create a program or function that calculates and outputs the cube root of a number that's given as input.
The rules:
No external resources
No use of built-in cube root functions.
No use of methods/operators that can raise a number to a power (that includes square root, 4th root, etc.).... |
Write a code to display "I Love You".
Without using any built-in tools or functions like echo, System.out.println, printf, ...
You are not allowed to directly call any function throughout the program execution, but the system environment or the compiler-generated code might do. This way, you can put your code in a mai... |
A weird number is a number that the sum of proper divisors is greater than the number itself and no subset of proper divisors sum to that number.
Examples:
70 is a weird number because its proper divisors (1, 2, 5, 7, 10, 14, and 35) sum to 74, which is greater than 70, and no combination of these numbers sum to 70.
1... |
Create a piece of code and a genuinely-looking test for it. However, the test must be flaky: when run multiple times, it must sometimes fail, sometimes succeed.
Be creative and try to hide the flakiness as much as possible. The most popular answer in (at least) 10 days wins.
|
The goal is to calculate all the squares up to x with addition and subtraction.
Rules:
The code must be a function which takes the total number of squares to generate, and returns an array containing all those squares.
You can not use strings, structures, multiplication, division, or built-in functions for calculating... |
You are to write a program that will output source code that is
Larger than the original program (character wise)
Will print another program larger than itself when run (i.e. the new program is also a valid answer to this challenge) indefinitely
This is code-golf, so shortest answer wins.
|
Douglas Adams was born on March 11, 1952, and died when he was just 49. In honor of this wonderful writer, I challenge you to display 42 in the most creative way possible.
You could print it in the log, via some convoluted method, or display it as ASCII art, or anything! Just come up with a creative method of displayin... |
EDIT: If you're using Lisp, I have given some guidelines at the bottom in counting bytes.
Objective: Make the shortest function that splits a string at non-digits and returns an array consisting of only digits in each string, without the use of any regular expressions. Leading zeroes are to be included in each string.
... |
The idea here is to write a little segment that will spit out regular expression patterns when given a string that matches them.
As you might have guessed, this will be a popularity contest, and I'll accept whichever answer has the most upvotes by March 7th
pseudocode Example:
print(reverseRegex('dog'));
//prints /[a-... |
Chris, a cryptic crosswords addict, has a set algorithm for the order in which he solves them.
We will use the above image as a guide.
Chris always starts off with the first across clue, in this case 1 Across. Chris is a capable crossword enthusiast, so it is assumed that he will always know the answer to the clue he... |
The 32-point compass is... interesting, to say the least.
By Denelson83 (Own work) [GFDL or CC-BY-SA-3.0], via Wikimedia Commons
Your challenge is to take a degree measure, and convert it into a direction on the 32-point compass.
Each direction is 11.25 (360 / 32) degrees farther than the previous. For example, N (nor... |
Write a polyglot (code that works in two or more languages) that has a "mid-section" that can be modified to do any computational task. This question is similar to https://stackoverflow.com/questions/1053931/code-golf-shortest-turing-complete-interpreter.
Rules:
The program must be able to preform a computation and pri... |
Task:
Make a random number generator. The catch is that you can't use any built-in randomness functions. Your random numbers must be anything between 0 and 100, though they do not have to be floating point.
Rules:
It must produce a pseudorandom number.
Randomness defined: If you run it x times, then x times again, the... |
The Challenge
You must calculate pi in the shortest length you can. Any language is welcome to join and you can use any formula to calculate pi. It must be able to calculate pi to at least 5 decimal places. Shortest, would be measured in characters. Competition lasts for 48 hours. Begin.
Note: This similar question st... |
In this challenge, you get to create a language. Although you have to provide code in other languages, you will only be rated based on the language. Here are the requirements.
You must invent a programming language that is Turing complete.
You will choose a real (as in existed before this question did) language. It mu... |
The goal is to write a program (anything except explicit brainfuck) which prints Barney Stinson's best rule:
New is always better.
when interpreted normally, but
Legen... wait for it... dary!
When processed with a Brainfuck interpreter.
May the most popular bro win. You have 72 hours to be legendary.
|
It's geeky to see a Boolean Matrix animation, but a live one would be better. Echoing only 1s and 0s create a program that creates an infinite loop of integer matrix.
1s and 0s are randomly echoed like an error.
|
Similar to the images on allrgb.com, make images where each pixel is a unique color (no color is used twice and no color is missing).
Give a program that generates such an image, along with a screenshot or file of the output (upload as PNG).
Create the image purely algorithmically.
Image must be 256×128 (or grid that ... |
Implement a function divide(int a, int b, int c) that prints the base 10 value of a/b. without using any floating point math nor BigInteger/BigDecimal or equivalent libraries whatsoever. At least c accurate characters within the set of 0123456789. must be printed, except for the (possible) exception in point 4 below.
... |
Create the shortest program to check who has won in an nd tic tac toe game.
Your program should work when n (width) and d (dimension number) are in these ranges:
n∈[3,6]∩ℕ ie a number from this list: 3,4,5,6
d∈[2,5]∩ℕ ie a number from this list: 2,3,4,5
n = 3; d = 2 (32 ie 3 by 3):
[][][]
[][][]
[][][]
n = 3; d = 3... |
I am looking for either suggestions or examples of more famous sayings written in code! If you have a website or database of them, please link that below your favorite one!
Examples:
while(!(succeed = try()))
if(lifegivesyou == lemons) {makelemonade();)
|
With the big crash of the universal economy also the demand for custom made planets plunged. The Magratheans had to look after more steady revenues also from a broader class of customers. Therefore, they invented the have-your-own chain of mountain (or short havoc-o-mountains) for people with smaller budget who could n... |
It's the ending of another well played chess game. You're the white player, and you still have a rook and your king. Your opponent only has his king left.
Since you're white, it's your turn. Create a program to play this chess match. Its output can be a sequence of moves, a gif animation, ASCII art or whatever you like... |
Write a function or program that takes in a list and produces a list of the local extremes.
In a list [x_0, x_1, x_2...] a local extreme is an x_i such that x_(i-1) < x_i and x_(i+1) < x_i or x_(i-1) > x_i and x_(i+1) > x_i. Notice that the first and last elements of the list can never be local extremes.
So for some ex... |
Your mission is to write a program that accepts a date in the formats 2014-02-27 (calendar date) and 2014-W09-4 (week date) from standard input and outputs the date in the format it wasn't entered in (to standard output with a trailing newline). The dates must conform to the standard ISO 8601, i.e. with weeks that star... |
A Kaprekar number is an n-digit number k that, when the first n or n-1 digits of k^2 are added to the second n the digits of N^2, the result is N.
Examples:
9^2 = 81. 8+1 = 9.
45^2 = 2025. 20+25 = 45.
297^2 = 88,209. 88+209 = 297
The Kaprekar sequence begins at 1.
Write a program that calculates and outputs the firs... |
Ruby comes with a built-in REPL, which is quite handy.
Your challenge is to crash it in the least amount of code!
The definition of "crash" is "make it exit in an unintended way." This means exit, quit, abort, irb_exit, irb_quit, et. al. are not valid answers.
Furthermore, you may not cause any side-effect to any othe... |
Given an integer array, write a program that determines if it is sorted in ascending order.
Remember that this is a code trolling question.
I am looking for most interesting ways that people come up with.
The answer with most upvotes wins.
This question is inspired by a 'creative' solution that a candidate gave me in a... |
I would like to see who can make Python have a fatal crash with the most creative code. This means that when the program runs, Windows for example, will take over and pop up with something like “IDLE has stopped working”, or Linux will do whatever Linux does when a program crashes.
Rules:
This must be made in Python 2... |
Write a program to output the part of speech of any word inputted to it. I doubt that anyone could get a perfect algorithm, so I will give the code a batch of words in order to ascertain what algorithm is the best.
Weighted Scoring:
+10pts for each word identified correctly: http://www.englishclub.com/grammar/parts-of... |
The challenge is to find the shortest implementation of the game of life in 3D (example). These are the rules:
Cells (in this case, cubes) with only 1 or less neighbours die, as if by lonliness.
If exactly 5 cells surround an empty cell, they breed and fill it.
If a cell has 8 or more neighbours, it dies from overcrowd... |
Your job is to generate a heightmap and show it as a parallel projected, voxel landscape. The rules are the following:
The (heightmap of the) landscape has to be randomly generated
You also have to describe how the algorithm you are using works, so everyone can learn something new here
You have to also either generate... |
Create a Sudoku solution CHECKER
There are oodles of Sudoku SOLVERS here, but I want you to create a solution CHECKER as small as humanly possible (code-golf).
A valid entry will be able to either take a 9x9 array as an argument (passed by reference, serialized on the command line, or however you want to take it) or... |
Your job is to write a program to find the closest number to PI.
Let me clarify.
You will first choose a number type. Let us say you choose Integer (in an actual answer, you cannot). Your program would then have to generate an integer that is closed to PI. For Integers, this would be 3. Not 4; 3.
For every allowed numb... |
Write a program that reads from stdin two integers, each newline terminated, hereafter called "number" and "radix", and:
Prints any fixed message you want if the number is a palindrome in that radix (e.g. true, t, 1)
Prints any different fixed message you want if the number is not a palindrome in that radix (e.g. fals... |
Task:
You must create an interpreter that can parse snippets of a programming language. The language does not need to be complex, but it must include the following syntactical elements:
Ability to assign and read variables (could be as simple as a-z being premade variables)
If statements (elseif and else are not requi... |
Inspired by a now deleted StackOverflow question. Can you come up with a way to get a particular method executed, without explicitly calling it? The more indirect it is, the better.
Here's what I mean, exactly (C used just for exemplification, all languages accepted):
// Call this.
void the_function(void)
{
printf... |
Everyone knows the phrase "Rules are made to be broken!", so here is your task:
Write some code in any language that breaks a standard. This can be anything, from putting
240 volts down a USB cable, to pinging your router (NOT somebody else's website!) with a 10mb packet! (Don't get any ideas, both of these will proba... |
You will take input such as
http://examples.example.co.nz/abcdefg
and return the name of the website, in which this example would be example.
To be more specific, I am looking for the Second Level Domain, which immediately precedes the TLD (Top Level Domain), but the Third Level Domain if the website is a Country Code ... |
Create a deterministic program to play nd tic-tac-toe with the other contestants.
Your program should work when n (width) and d (dimension number) are in these ranges:
n∈[3,∞)∩ℕ ie a natural number greater than 2
d∈[2,∞)∩ℕ ie a natural number greater than 1
n = 3; d = 2 (32 ie 3 by 3):
[][][]
[][][]
[][][]
n = 3; ... |
Task:
Create an obfuscated program that prints Hello World! (exactly like that). Your program may not have any strings in it.
Rules:
You can use any programming language you like.
Make it as obfuscated as possible
This is a popularity-contest, so the answer with the most upvotes wins.
Note:
This is not a duplicate o... |
Task:
Create a program that will take an acronym as input, for example dftba, and generate some possible phrases that the acronym could stand for. You can use wordlist as word input. Inspired by https://www.youtube.com/watch?v=oPUxnpIWt6E
Example:
input: dftba
output: don't forget to be awesome
Rules:
Your program ca... |
Write a program to solve a series of linear equations as short as possible. It must solve arbitrary number of equations problems. They can inputted however you like, coefficients of augmented matrix is probably the easiest. The program doesn't have to handle non-integer coefficients or solutions. No degenerate or inval... |
Your challenge is to take input like this (a Hello World program):
++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++.
And output a prompt (which will be "> "):
>
The user can then enter anything at the prompt. Your simple debugger must have these commands:
S - ... |
Create a program to display some approximation of a bell curve. You are free to use whatever method you wish for generating the data, but the data must be displayed vertically, as in oriented like so:
Other restrictions:
Your code must create the approximation, that is, don't hardcode or take data from the internet.
... |
The Utah teapot, originally created by Martin Newell, is a convenient object for testing 3D graphics programs.
The task is to create a wireframe image of the teapot in perspective projection. To encourage the idea of a source-code application, the viewing and camera control may be isolated and excluded from the count. ... |
Write a program that produces mirror images of itself. An example, would be the fantastic camel code that reads it's own code and produces two smaller 2x2 versions. Given the input:
$_='ev
al("seek\040D
ATA,0, ... |
Computers do not out-of-nowhere create random numbers without basis, as most likely, time is the universal basis of randomness.
I want you to create a code that creates random numbers with these rules:
Time is not allowed to be the basis, at any point of the program.
Predefined random/pseudo-random functions are not a... |
Your task here is to write two regular expressions, each of which matches the other one but does not match itself.
Both regular expressions should have this form:
/pattern/optional-flags
This is also the form in which they should be matched.
The shortest solution wins. The solution length is counted as the sum of char... |
Here's an interesting challenge...
I want you to golf code that when executed will allow your input to be converted to mimic output as though you were typing on a DVORAK keyboard layout.
The aim is to mimic the US Simplified Dvorak Keyboard (US:SDK)
In comparison, here is the standard US QWERTY layout:
The keyboard e... |
Your job, for this golf, is to write a program that will take moves of a game of reversi (othello) and display the result to the user.
Input
A string of numbers taken from the range [0-7]. Each pair of numbers represent first the X coordinate, then the Y coordinate. Any characters not in that range should be ignored.
O... |
Provided an input as an unsigned integer:
13457
Your function/subroutine should return:
75431
Since this is a popularity contest, be creative. Creative solutions use unusual or clever techniques to accomplish given task.
Constraints:
You cannot use arrays.
You cannot use strings.
No RTL Override (‮)
Brownie po... |
This challenge challenges you to write a function that will take as its argument an array that specifies the types of input, an optional prompt, and a verification key; inputs and validates the values; and returns them.
Input types:
b - Boolean values.
c - Characters.
i - Integer values, rejects floating point val... |
Challenge: Implement ROT-47 in code that works as both itself and as the ROT-47 version of itself.
Scoring:
Your score is calculated as a percentage of used, ROT-47 eligible bytes in total of both versions of the program divided by total bytes (all characters) of both versions.
A used, ROT-47 eligible byte is any chara... |
Write the shortest program you can that displays a red 3D cube.
Rules:
The cube must be red, have 6 rendered sides, and be displayed in 3D.
Your program cannot load any textures.
More than 1 side must be visible.
The result does not need to be rotatable.
|
I seem to have gotten myself into a bit of a pickle. Literally. I dropped a bunch of pickles on the floor and now they're all scattered about! I need you to help me collect them all. Oh, did I mention I have a bunch of robots at my command? (They're also all scattered all over the place; I'm really bad at organizing th... |
Imagine the following scenario: you are playing battleships with a friend but decide to cheat. Rather than moving a ship after he shoots where your ship used to be, you decide not to place any ships at all. You tell him all his shots are misses, until it is impossible to place ships in such a way.
You have to write a f... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.