@hyper-neutrino If 2 users complete a "Delete" review in the LQP queue, then it take 4 more "Recommend Deletion" reviews to delete it (and 1 "Delete" requires 5 "Recommend deletion"). However, 3 "Delete" reviews will delete it, regardless of how many "Recommend Deletion" reviews were done. So you can have anywhere between 3 and 6 reviews to delete a VLQ post
(Ignoring mods who make 1 and 2 reviews possible as well)
@Adám I just want to know if abcde has a maximal number of other strings within Levenshtein distance 2 . That is, is there another 5 letter strings over the alphabet a-e which has more strings within Levenshtein distance 2?
The first step is to count how many strings are within Levenshtein distance 2 of abcde which you can do just by brute force
@RedwolfPrograms I am interested in the size of the Levenshtein ball. It's apparently useful but I like the question independent of how useful it is :)
@Anush Yes, but I'm not sure what it does as a whole. You're getting the powerset of each element in a list, then keeping the elements that appear in all of them, then taking the last one's length (call that L). Then you get the lengths of each element in the input, get the abs differences with L, then take the sum
ŒP€f/ṪLạẈS € On each of the original strings ŒP produce all possible subsequences of the string; f take the list of common elements / between the first and second sets of subsequences; L take the length of Ṫ the last of these common elements; ạ take the absolute differences between that and Ẉ the length of each {of the original strings} S and sum them.
Jelly, 10 bytes
ŒP€f/ṪLạẈS
Try it online!
A port to Jelly of my Brachylog answer, saving a few bytes through more convenient plumbing and some convenient builtins (and beating the builtin-based practical language answers by being shorter than the word "Levenshtein"). This is a function submissio...
Who Won Tic-Tac-Toe?
Your job is to be the judge of a game of Tic-Tac-Toe.
Given an input consisting of three lines (9 characters not including newlines), determine the winner of the game of Tic-Tac-Toe.
For example, for the input
XOO
-XO
O-X
your program should either return or print X.
For tie...
@RedwolfPrograms Yep. I'm still watching the demo, so I'm not 100% sure/sold on the new changes, but I've upvoted because it's a very promising first step
Just wrote a couple hundred lines of Rust code that's, if I may say so, quite fancy and industry-grade. I think all the abstraction also makes it much cleaner, easier to understand, and more maintainable. What do y'all think of it?
Stop stealing stuff from the starb...oh wait you're the one who posted that earlier
So uh...one of the assignments we got for school online had all of the answers filled in already, and I let the teacher know, and they fixed it. But they included a comment explaining what happened and it included my name and I don't think people are that happy with me ._.
We had a kid in our class once who reminded the teacher about the test we were supposed to have. That day, he learnt a lesson not scheduled: snitches get stiches tons of people yelling at him and throwing pencils
> Generally a person can leave money to any person or organization that the testator pleases. In some US states, a minimum potion must be left to family (spouse and/or children).
What is a good way to learn Jelly? I've read the tutorial and am very confused. Is there maybe a list of challenges that are simple to solve in Jelly, or perhaps categorized by what features of Jelly one must know?
@NieDzejkob This is a good list of exercises to get started with, and hyper has a site specifically for learning Jelly, which is supposed to be good, and I have my (in progress) Recipes for Jelly, which are all good resources to start
Speaking of, I really should do more work on my Recipes for Jelly
CMC for the nerds here: Briefly explain SVMs for a non-nerd and which parameters might be best for different stuff
Alternate CMC for the nerds: Make and train SVMs for me. Since I'm generous, I won't be accepting payment and will let you do it for free (an iced tea would be appreciated, though).
@Dudecoinheringaahing I think geek mostly just implies knowing a lot about some topic and being excited about it, whereas nerd kinda implies being good at math, science stuff, etc. but not at any real life stuff
@Dudecoinheringaahing I'm sure the connotations are different in different groups & dialects. Although I think I remember being told something similar when I was junior-high-school age.
@Dudecoinheringaahing Anti-ninja'd, really: I was saying "what if you know a lot about some topic and you're good at math & science and you're not good at real life"
Come to think of it, maybe my positive view of the term "nerd" comes from the Age of Empires II (and possibly other RTS games) usage "micro-nerd," meaning somebody who's extremely good at micromanaging their military units in battle.
@DLosc Well, I only played it a couple times, realized I sucked at it, and then deleted it to save space or something, but I do remember thinking it was a cool game :P
@Dudecoinheringaahing So then something like this (not sure how to score it). TI is a function that maps trees to (nonnegative) integers, and IT maps integers to trees.
Tree-to-integer is basically just "count the depth." Integer-to-tree is "start with empty list and wrap two copies of the previous level in a list N times." Both are recursive functions.
If the CMC submission can be two separate full programs, then a?URE@a0 and a?[RE Da]RL2l work in modern Pip with -xp flags, for 8 + 14 = 22 bytes total.
@Bubbler No? These are full binary trees without values on the nodes, which means that there's only one possible tree of a given depth, if I'm not mistaken.
Nah, math isn't the problem. Trying to map math to English is the problem.
Actually, in this case, that's not even the problem. "Every node has either 0 or 2 children" is perfectly clear (if you know the definitions of "node" and "children"). The problem is trying to come up with a single-word name for each type of tree.
@DLosc zero-or-two-child-nodes-tree and now you have a Lisp programmer :P
@user [context: Dotty (now Scala 3) was a major rewrite of Scala. This is an April Fools' article that pretends they're going to make Scala 3 German (Skala 3). Apparently, the example program actually worked (and maybe still does)]
> We took choosing the new German keywords as an opportunity to improve upon their old English variants. For example, ich sounds much more personal than this, implementationsdefiniert conveys the meaning of abstract so much more concretely, and erbt saves typing a few characters over the more verbose extends.
@user This article that Adám linked compared learning Haskell to learning German, and I thought it was a good comparison. Case in point: it's "Brot," not "brot," because German capitalizes all its nouns. :P
@Adám Interesting read, that functional programming article. I've tried to Learn Me a Haskell for Great Good a couple of times and not gotten much of anywhere... maybe I should start with Elm like that author suggests.
fn is a particularly unfortunate choice of a variable name, methinks... I guess it stands for "fibonacci number," but my brain automatically reads it as "function"