Me too :( My answer is perfect for the first quadrant, but has a few lines of error on the reflections. Not something I can fix without sacrificing some serious bytes.
Hm... even in imaginary GolfPython (*not Pyth) where zip returns lists of lists and print is both a statement and a function... I'd still be a byte short from 2x
I can get the first quadrant with zero errors for just a few more bytes. (I added almost 100 errors to save two bytes) ... but the remaining ones are then due to the lack of rotational symmetry in the binarisation
Digits Digging a Dungeon
code-golf simulation numbers
Given a non-decreasing list of one-digit positive integers, you should determine how deep dungeon they will dig.
Before the start of the digging the ground is level.
███ ███ A dungeon with 5 blocks removed and a depth of 3.
███ ███
███ ...
proving/disproving the greedy method's optimality become a bonus puzzle
I was thinking that could be a first step to proving greedy's optimal
I was trying to come up with an example like 3x1 and 3x2, where you have to do
11
21
2
2
which is nongreedy, but in this case you can switch that around and do this instead:
11
21
2
2
And the thing is in the first one, all of them are forced to jump the max height they can jump, but in the second that's not the case for, say, the left column's 2
So I was wondering if you could do some sort of "the greedy algorithm guarantees keeping the best set of digits remaining after each move" argument, but I'm not sure
well greedy using the digits in increasing order so it keeps the best set in pure values
your one-side statement could help a lot as it might be used inductively for the next columns as those could also be approached from one side (the shallower one)
Does anyone know about Community Wiki notification rules?
Will comments on my sandbox answer show up in my notifications now that my answer is CW? That's my main concern, especially if we are using comment notification to check if old answers are eligible for being adopted by someone else. — trichoplax52 secs ago
i my question , there s quiet diversity of solutions , case-separated , (x/xy) or(x/x+y) for whichever y>0 is would give 0 , (x+3)/(x+2) is 1 but (x+4)/(x+2) isnt always 1 (case x=0) so cantbe simplified . otherwise it is 1+1/(x+2) in all cases if division is floating , so what about rolling it back to first edit ?
My problem with the arithmetic expressions question is that it's too hard for me, e.g. what's the optimal for x,x,x,x,x,*,*,*,*,x,x,x,*,*,-,x,x,*,+,1,-?
Non-crossing X's and crossing non-X's
code-golf string counting
You should write a program or function which given a text as input outputs or returns the sum of the following three integers:
Number of lowercase x's which are not part of a cross-formation.
Number of uppercase X's which are no...
@AbdouAbdou yes. you write a program (in any language), which is given a number as input. the output of your program is a stickstack program which outputs the requested number (and should be as short as possible).
This is probably duplicate but haven't found a similar question. You have N dices in an infinte-by-K-by-1 transparent box. You see the forward facing side of every dice. After scrambling there will be K dices at the bottom. What is the exact chance that those bottom sides a)will be a given list b)will have a sum of a given number. Is this too boring?
I think I did. Given the forward faces of some dice, find the probabilities of the bottoms matching a) or b). I'm with Martin on the infinity thing, though.
btw, little nitpick: the singular is technically "die" (although I believe "dice" has become acceptable by now), but the plural is definitely "dice" ;)
when you first said "transparent" and "dice" I was wondering whether there would be an interesting challenge of lining up transparent dice, looking through them and doing something with the number of pips you see.
Mom told me that when I was around 6 or 7 I sounded like a hick, and they had to coach me out of it by correcting me a hundred times a day on pronunciations
I think if I went for the straightforward probability theory challenge, then doing a simple d6 with four probabilities would be the right difficulty level
Here's another pic from his profile on UX (which randomly showed up while I was searching his profile text to see where he stole it from): ux.stackexchange.com/users/6517/tom
after two failed challenges , idont think i really understand how it goes here ! besides , i did remarked that matlab isnt currently used in this SE part
@AbdouAbdou I'm not sure if I already mentioned it, but a great way to find out if a challenge would be successful and if it's clear and on topic is to first post it in the sandbox and leave it there for a few days to get feedback.
It also helps (most people) to hang out and answer some challenges first. That helps you see how it works better, so your own are better than they would be.
Another idea I thinking about is this: Find the greatest x that you can connect (0,0) and (0,x) with a given set of tetris pieces. Connection is orthogonal.
Speaking of stacking tetris pieces, I received this as a gift, but really have nowhere to put it. Fun to play with for a few minutes, then just.... an oddball lamp.
@Geobits I like to be able to see my keyboard at night. I don't like bright lights, but I don't like lights that are too dim to see my keyboard either.
Currently I have this ridiculously bright lamp pointed at the ceiling. I'd love a somewhat dim Tetris lamp sitting on the edge of the desk right near my keyboard
Welcome to Puzzling SE! Are you asking for a program to solve this problem? If so, codegolf.stackexchange.com would be a more appropriate place to do it :-) — leoll22 hours ago
What kind of question is this (from Visual Studio)? "SomeFile.cs has been changed in an open editor an also on disk. Do you want to not save your changes and replace the file on disk?"
But here's the thing... every other time I have a file open in an editor and forget to press save, and then I get latest version, it just says "You have unsaved changes in file.cs. Would you like to save them before getting latest version?"
And then after that, it says "File.cs has conflicting changes. Please merge." or something like that
And I reconcile the changes (or I give up at that point because they are unreconcilable) and then all is good