Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »

Activity for General Sebast1an‭

Type On... Excerpt Status Date
Edit Post #284117 Initial revision about 3 years ago
Answer A: A number adder, not a death adder
[PHP], 58 28 bytes P1: <?=$argv[1]+10; Try it online!
(more)
about 3 years ago
Edit Post #282472 Post edited:
about 3 years ago
Edit Post #284116 Initial revision about 3 years ago
Answer A: Evens or Odds - you know this one
[PHP], 36 bytes <?php $x=(int)fgets(STDIN);echo$x%2; Try it online! Outputs `1` if odd and `0` if even.
(more)
about 3 years ago
Edit Post #284115 Initial revision about 3 years ago
Answer A: Reverse an ASCII string
[PHP], 32 24 bytes <?=strrev(fgets(STDIN)); Try it online!
(more)
about 3 years ago
Edit Post #284114 Post edited:
about 3 years ago
Edit Post #284114 Post edited:
about 3 years ago
Edit Post #284114 Initial revision about 3 years ago
Answer A: 1, 2, Fizz, 4, Buzz!
[PHP], 114 bytes Philippine Peso this language, it was tricky.
(more)
about 3 years ago
Comment Post #284104 Noice, you beat my answer. Congrats!
(more)
about 3 years ago
Edit Post #284108 Initial revision about 3 years ago
Answer A: Tips for golfing in Python
Replace `range()` if $n for i in 0,1,2,3:print(i) Try it online!
(more)
about 3 years ago
Edit Post #284100 Post edited:
about 3 years ago
Comment Post #283971 @#53837 Thanks for catching that. Unfortunately, `Scanner` is the only way to set an input. At least I got rid of the string assignment.
(more)
about 3 years ago
Edit Post #283971 Post edited:
about 3 years ago
Edit Post #284100 Initial revision about 3 years ago
Answer A: Repeat the characters
[Python 3], 53 38 bytes def f(x,y): &#9;for c in x:print(end=cy) Try it online! I'm sure someone will find a `lambda` solution to this. Golfed 15 bytes thanks to @Moshi's advice.
(more)
about 3 years ago
Edit Post #284091 Post edited:
about 3 years ago
Edit Post #284091 Initial revision about 3 years ago
Answer A: "Hello, {name}!"
[PHP], 55 27 21 bytes Hello, ! Try it online! Golfed 28 bytes thanks to my Software CD post. Golfed 6 bytes thanks to @Shaggy's advice.
(more)
about 3 years ago
Edit Post #283948 Post edited:
about 3 years ago
Edit Post #284088 Initial revision about 3 years ago
Question Define a mathematical expression in English
Background Inspired by this challenge that is also a mathematical English translator. Challenge Write a program that translates a mathematical expression using English with the following specifications: - The expression can only take in numbers, letters from the English alphabet, the equa...
(more)
about 3 years ago
Comment Post #284087 I suppose an example is the `Hello, World!` challenge, but users should be creative.
(more)
about 3 years ago
Comment Post #283946 @#8176 Yep, that's <a class="badge is-tag">popularity-contest</a>. In fact, I edited it to answer your question.
(more)
about 3 years ago
Edit Post #283946 Post edited:
about 3 years ago
Edit Post #284079 Post edited:
about 3 years ago
Edit Post #284079 Post edited:
about 3 years ago
Edit Post #284080 Initial revision about 3 years ago
Answer A: Suggestions for the new header banner/background
Binary and code plastered a lot One of the more generic ways of adding design to a code challenge site. The binary digits can be plastered around the header in a way that it looks cryptic. But binary is not enough, we can also have code of certain languages for some diversity. What's more cool ...
(more)
about 3 years ago
Edit Post #284079 Initial revision about 3 years ago
Answer A: Digit Sum Integer Sequence (working title)
[Python 3], 183 181 175 bytes def f(a,b): &#9;c=a;a=str(a) &#9;for i in range(b): &#9;&#9;y=0;z=9 &#9;&#9;for j in range(len(a)): &#9;&#9;&#9;if y&lt;int(a[j]):y=int(a[j]) &#9;&#9;&#9;if z&gt;int(a[j]):z=int(a[j]) &#9;&#9;c=int(a)+y+z;a=str(c) &#9;print(c) Try it online! I deci...
(more)
about 3 years ago
Comment Post #284068 I hope you get a title that you'd like to use.
(more)
about 3 years ago
Suggested Edit Post #279696 Suggested edit:

(more)
helpful about 3 years ago
Edit Post #284066 Initial revision about 3 years ago
Answer A: Tips for golfing in Python
Assign `float`s while leaving out zeroes Python allows such strange assignment. You can save bytes by removing the number preceding `.` if it's only `0`: i=.5 print(i) Try it online! The same goes for succeeding digits, if the decimal part of the `float` is `0`: ...
(more)
about 3 years ago
Edit Post #283858 Post edited:
about 3 years ago
Edit Post #284023 Post edited:
about 3 years ago
Edit Post #284040 Post edited:
about 3 years ago
Edit Post #284064 Initial revision about 3 years ago
Answer A: Reverse an ASCII string
[Lua], 32 bytes print(string.reverse(io.read())) Try it online! Noice built-in.
(more)
about 3 years ago
Edit Post #284063 Initial revision about 3 years ago
Answer A: Getting perfect squares, differently
[Lua], 41 40 bytes x=0 y=1while""do print(x)x=x+y y=y+2 end Try it online!
(more)
about 3 years ago
Edit Post #284062 Initial revision about 3 years ago
Answer A: A number adder, not a death adder
[Lua], 51 bytes P1: print("print(tonumber(io.read())+"..io.read()..")") Try it online! P2 (given I inputted 10, 29 bytes): print(tonumber(io.read())+10) Try it online!
(more)
about 3 years ago
Edit Post #284040 Post edited:
about 3 years ago
Edit Post #284061 Initial revision about 3 years ago
Answer A: Tips for golfing in Python
Renaming functions A funny, cool, and useful trick. If you have to write a single function multiple times (usually `range()` on `for` loops), then you can simply assign a variable by the function's name, no parentheses. An example assignment is: ``` r=range ``` Thing is, this can only appl...
(more)
about 3 years ago