Linked Questions

8
votes
8answers
619 views

1, 2, 3, 4, 5, Shaggy [duplicate]

This is my first code golf exercise for you: Your input is two integers n and k. You can assume n >= 1 and k >= 1 You have to output all numbers from 1 to n (inclusively) and replace every element ...
281
votes
148answers
94k views

Tips for golfing in Python

What general tips do you have for golfing in Python? I'm looking for ideas which can be applied to code-golf problems and which are also at least somewhat specific to Python (e.g. "remove comments" is ...
58
votes
118answers
15k views

Duck, duck, goose!

Remember the kids game, 'Duck, Duck, Goose'? No? Me neither. The challenge Print the word 'duck' on individual lines an indeterminate amount of times. Print the word 'goose'. Your program ends. The ...
88
votes
57answers
11k views

BrainF***edBotsForBattling - A Brainf*** Tournament

All bots at the battle arena suddenly got brainfucked and no one can explain why. But who cares as long as they are still able to fight - although Brainfuck is the only language they understand ...
45
votes
47answers
5k views

Count without 3

Background When I was in elementary school, we used to play a game in math class that goes as follows. All kids sit in a big circle and take turns counting, starting from 1. However, the following ...
38
votes
51answers
7k views

Don't give me five!

Question : You will be given the starting and ending integers of a sequence and should return the number of integers within it which do not contain the digit 5. The ...
15
votes
24answers
5k views

Generate me some appropriate license plates!

The scenario: You are a software designer working for a gov't-run company that designs license plates for cars and other vehicles. You've been asked to develop software that generates license plates. ...
19
votes
8answers
2k views

Build a “BizzFuzz” program

In traditional FizzBuzz, you are asked to print the numbers from 1 to 100, but replacing every multiple of 3 with "Fizz", every multiple of 5 with "Buzz", and every multiple of both 3 and 5 (i.e. 15) ...
6
votes
2answers
275 views

Tips for golfing in MathGolf

What general tips do you have for golfing in MathGolf? I'm looking for ideas that can be applied to code golf problems in general that are at least somewhat specific to MathGolf (for tips which can be ...
0
votes
0answers
70 views

Let's play the boom-game! [duplicate]

back ground in my country we had a silly game as kids, called 7-BOOM! The rules are really simple. We counted 1,2,3... each time we had a number that one of his digit is 7 or it is a multiply of 7 ...