Would NNs even be a good choice for this? It doesn't seem like making a small change to a bitstring necessarily corresponds to a small change in the number of unique substrings
@Dennis well it will certainly not be exhaustive, but a decently sized (say, 20-30?) should filter most of it out unless people are deliberately trying to get around it
> Noun. clbuttic (uncountable) A type of error in which some bowdlerizing software garbles words by replacing objectionable words that occur within a word with tamer alternatives, such as the erroneous correction of "classic" to "clbuttic".
@user202729 Personally I wrote a brain-flak interpreter that goes through the code step by step with a visualisation of each stack (as well as the working stack) at each step
@user202729 well actually no. that's not a stated restriction, so since Dodos doesn't have negative numbers as a builtin type IMO it shouldn't be needed
I have found code-golf a fascinating pastime for several weeks now.
However, I’m already losing interest because the contests allow any language, and because of that it is pretty much impossible for anything other than J or GolfScript to get anywhere close to winning. As soon as I see a less-tha...
@Anush I do like the endless problems, it is a direct competition in golfing skill, normally in ppcg once I see another answer in the same language, I don't give it a try at all, but it doesn't happen in anagol
@totallyhuman Here's the real deal - I got poked about this earlier and while I did reply, I didn't actually answer the question properly, oops. At any rate - consider it noted for review.
A lot of moths have passes since and this should really be trivial to enable...
99 bugs in the code
The adaption of "99 bottles of beer on the wall" for computer science where the bugs increase instead of the bottles decreasing is often re-posted around the internet. Example T-Shirt Here.
I think it'll be interesting to see recursion and random number generation across a h...
@Mr.Xcoder I didn't see that one and thought it has been forgotten since February.. Then again this was over a a month (or moth?) ago too. I doubt that this would be a lot of work, but maybe I'm wrong.
This is a real problem that I just encountered.
I am using a proprietary API that somebody else has created.
There is a call to get the color of an object. The color is denoted to be of type uint in C++. The documentation of the API does not say anything about the value to be returned for obje...
CMC: Given the mana cost of a Magic: the Gathering card, return its CMC (Converted Mana Cost). X is considered to be 0. e.g. "3RR" -> "5", "11G" -> "12", "XRR" -> "2", "WUBRG" -> "5"
@Emigna In Magic, all the numbers come front loaded such as "5WR" or "XXRR" or "10WWGGG". Sorry for not being more specific in my original problem statement, I didn't stop to think about all the assumptions that come with knowing what is and isn't valid in the game.
@DJMcMayhem In fact there are three answers containing \$ that are not in <code>-tags, however one of them tries to use MathJax, so 2 answers need to be fixed :)
These answers would be: 23089, 59050 (tries using MathJax) and 138058
I used this script (tio-link is too long) and the csv-data from this query
@BMO nah, they're just the same thing with a different representation. The only true difference is that you cannot pay for {C} with colored mana. But now, every land that generated {1} (or more) will generate {C} (or more) instead.
Ok that makes sense, it's still a bit weird when you're used to the 5 basic lands and colorless mana though. But I guess they had to make it a bit more difficult for all those crazy Eldrazi guys
@BMO yeah, but once you get it you'll see that basically nothing has changed other than the newer Eldrazi dudes. And yes, they were as unbalanced as they could possibly be, especially for standard.
Problem
Let's define a generalized Cantor set by iteratively deleting some rational length segments from the middle of all intervals that haven't yet been deleted, starting from a single continuous interval.
Given the relative lengths of segments to delete or not, and the number of iterations t...
After inputting a string [length 1-20], only cotaining the chars y for yes and n for no,
your program should output the result (y or n). Example input: yynynynny =y
The result is determined by combining the y's and n's in the following way:
yes and no equals no
yes and yes equals yes
no and no...
@Adám In C# locks are stored in a table of metadata that holds objects for the purpose of stuff like garbage collection. As such, you can't lock value types, only reference types.
@Pavel Fair enough, but isn't it a bit silly to have duplicate data types just for parallel programming? What about other paradigms — do they need their own types as well‽
@Adám Lower level languages like C just aren't thread safe and require you build thread-safe systems yourself from the ground up. Higher level languages might gurantee thread safety for certain types, but then you end up paying the cost in performance for when it isn't necessary.
@Pavel OK, I guess that's a good argument when performance is key. However, for the everyday programmer that just needs the job done, the added complexity (in programmer-hours!) of additional types is probably worth the hit in performance.
C# (and Java, and other languages of a similar level) sit in that spot where performance is critical enough that having multiple implementations for each basic type for many common usecases is neccessary, but not so critical that the programmer makes custom types for his individual usecase.
@Adám Well no, because you still have your basic "use this if unsure" type. While you're working, you can just use List everywhere, and then later switch to a different kind of list if you realize it'll be faster, without much difficulty since all the provided lists implement ICollection.
@recursive It was invalid anyways because of that exact reason that the types became bool and str and the comparison didn't yield useful results.. Oh well, I think I'm no good at golfing with Python
I was inspired by a graphic of the longest interrupted lines on a pixel art site:
(image credit to JadeX#1046 on Discord)
So for this challenge, you must take an input image and output the top straight lines in the image, including the start position, end position (dx and dy), length (l), and...