Timeline for Tips for golfing in 05AB1E
Current License: CC BY-SA 4.0
17 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Sep 9, 2022 at 11:49 | comment | added | Kevin Cruijssen |
‚ on an empty stack with no input gives ["", ""] (not sure if it's ever useful, but figured I'd mention it either way).
|
|
| Feb 5, 2022 at 19:04 | comment | added | Oliver |
@Adnan Python 2 rounds down ("integer" division) the result. Python 3 should give 0.75. (To access the old behavior, use //.)
|
|
| Jun 17, 2020 at 9:04 | history | edited | Community Bot |
Commonmark migration
|
|
| Apr 9, 2019 at 18:49 | comment | added | Magic Octopus Urn |
) also pushes [] if the stack is empty.
|
|
| Apr 9, 2019 at 18:29 | history | edited | Kevin Cruijssen | CC BY-SA 4.0 |
Removed my name since I had nothing to do with it; and clarified some of the variables
|
| Feb 23, 2019 at 12:17 | comment | added | Kevin Cruijssen | @Adnan Btw, that second one was found by Emigna alone, I had nothing to do with it, except forwarding it to you ;) | |
| Feb 23, 2019 at 9:40 | comment | added | Adnan | @KevinCruijssen Thanks! I've added them to the list. | |
| Feb 23, 2019 at 9:40 | history | edited | Adnan | CC BY-SA 4.0 |
added 330 characters in body
|
| Feb 22, 2019 at 11:54 | comment | added | Kevin Cruijssen |
Two that could perhaps be added: ˆ pushes an empty array [] (I use this one pretty often). And ¸ without input pushes an empty array filled with an empty string [""] (very conditional since most challenges have input, but I've seen it used once).
|
|
| May 16, 2017 at 22:09 | comment | added | Magic Octopus Urn | @adnan that python comment was gold, and if this was reddit I would've given you 2ドル.99 in gold for it lol. | |
| Mar 8, 2017 at 21:46 | comment | added | Adnan | @mbomb007 Yep, kinda useless though. I haven't found a case where that was needed :p. | |
| Mar 8, 2017 at 21:23 | comment | added | mbomb007 |
If at the beginning, M pushes -Inf.
|
|
| Oct 16, 2016 at 14:13 | comment | added | Adnan |
No idea what you all are talking about :p. print(3 / 4) in Python 2 gives me 0.
|
|
| Oct 16, 2016 at 14:10 | comment | added | ETHproductions |
Back in my day, ¾ meant .75, and I once beat Pyth with that fact. These newfangled golfing languages don't have a clue about mnemonics...
|
|
| Oct 16, 2016 at 12:31 | comment | added | Emigna |
@Fatalize: 0 pushes 0 as well. ¾ pushes a counter variable which is initialized as 0. If you only want to push 0, 0 is of course more natural, but if you want to push 5,0,7, 5¾7 is 2 bytes shorter than 5 0 7.
|
|
| Oct 16, 2016 at 12:23 | comment | added | Fatalize |
¾ pushes 0 => that's about as non-mnemonic as it gets
|
|
| Oct 16, 2016 at 11:13 | history | answered | Adnan | CC BY-SA 3.0 |