Posts by General Sebast1an
Challenge Make a program that takes input of 3 non-negative integers: a result and 2 other values that once calculated results to the 3rd value. The program must figure out how to get the 2 fir...
Background Check out this video on the Collatz conjecture, also known as A006577. If you don't know what this is, we're given an equation of $3x + 1$, and it is applied this way: If $x$ is odd...
Disclaimer This challenge also exists in CGCC, but if you want to compete here (too), then hop in! Challenge Recreate "99 Bottles of Beer on the Wall", using the least bytes possible. Lyrics: ...
I have seen KOTH (King of the Hill) challenges before but it's still unclear to me how to properly make, or even play, such challenge. To get started, how do I make (or solve) KOTHs? An answer cou...
Originally from Somewhere Else. I thought I'd continue making more drawing challenges here now that I discovered it. Make the Stack Overflow logo using the following criteria: The tray: ...
Challenge Make a program that takes input of a string and abbreviate it. All letters of an abbreviation are capitalized, so keep that in mind. Whitespace, numbers and non-English characters ar...
Background Check out this video on the Collatz conjecture, also known as A006577[1]. If you don't know what this is, we're given an equation of $3x + 1$, and it is applied this way: If $x$ is ...
Introduction What is the Caesar shift cipher (ROT$n$)? It's basically a cipher sequence that changes a letter's value from the number chosen. If we use ROT1 on "games", we get "hbnft". The basic i...
I have this challenge in Code Golf and I wonder if I can repost it here for more users to come, and also continue making these since I actually like them. Can I post this challenge to Codidact?
Challenge Make a program that takes input of 3 non-negative integers: a result and 2 other values that once calculated results to the 3rd value. The program must figure out how to get the 2 fir...
Combine conditionals Python has its fair share of comparison operators and can actually be used in a single conditional. For example: x == 2 and y == 2 can be: x==y==2 Used on Make $2 + 2 ...
This is a feature-request post consisting of 2 actions for a reason... There's this thing that's been bugging me for a while in Code Golf CD. If you go to the tag page of the Challenges catego...
Background A House of I I went on an adventure Grabbed resources and making deeds Like start to work on the materials To build the shelter I need It was a marvelous one At least in the eyes ...
In this request (not really a feature-request but still tagged so anyway), I'd like to have detailed wikis on tags and maybe usage information on them too. Currently, these tags have usage info in...
C is a language I use most apart from Python and as someone who likes code golf challenges, what tips are there to golf in C?
What tips are there in fastest code, or what I like to call code speeding, challenges in Python?
Java (JDK), 311 301 296 bytes interface A{static void main(String[]x){String a=" bottle",b=" of beer",c=" on the wall. ",e;for(int i=99;i>0;i--){e=i>1?"s":"";System.out.println(i+a+e+b+c+(...
Use interface The special thing about this is that it lets you drop public when you originally call a class to run the main function. class F{public static void main(String[]a{}} interface M{sta...
Use for(;;) instead of while(true) The title's self-explanatory. A byte saver.
This is a list of golfing tips for the language known as Java. If you have a tip, add it in!
Python 3, 80 77 75 72 bytes def f(): yield 1;l=[*range(2,236425)] while l:yield l[0];del l[::l[0]] Try it online! Prints out the whole sequence. I did my best to get the biggest number t...
Challenge Write a program that prints its reversed self. For example, if your code is foo() Then it'll output: )(oof Make sure that the quine is a valid one, as defined here: No cheatin...
Use a+=[b] instead of a.append(b) The title says it all. a=[];b=10;print(a) a+=[b];print(a) Try it online!
* == and If you want to check if two booleans or integers and want to check if both of them are true in an if statement, then you can leave out and to replace it with *: x=2;y=3 if x and y:pri...
Combine loops Suppose you have a for loop in another, maybe a couple of times, and nothing else inside of the outer for loops (except for the first for loop since anything outside won't be involve...
