@Seggan If && has higher precedence than || (It does in JS): !(last is OpNode) || last.operator != Operator.PRINTLN && last.operator != Operator.PRINT_NO_NL
@DLosc Oh, that is a nice lang. Can't tell yet if it's different enough from Python to be interesting, nor if it offers enough golfing opportunities over Python for most CGCC challenges. It doesn't intrinsically seem golfier than Python, though.
The terminal repl has syntax highlighting which is quite interesting, though. (They've also taken care to develop syntax highlighting for a lot of editors, and the documentation does seem pretty long. Don't know for sure if necessarily thorough, but definitely had a lot of time invested.)
Is this graph a tree?
code-golf decision-problem graph-theory
Given an undirected graph, find out if it is a tree.
A tree is an undirected graph in which there is exactly one path between any two vertices.
Input
The input graph is represented as an adjacency list, i.e., a list of pairs that repr...
Anyway, there are several possible answers in that case... 1) there is absolutely no shorter way if you're using `unsigned char` only once 1.a) but sometimes simply using `int` or `char` will give correct results 2) standard solution: `#include <stdint.h>` and use `uint8_t` 3) hacky solution: `#define U unsigned char` and use `U` 4) less hacky solution: `typedef unsigned char U;` and use `U`
Radiation Hardening Koth king-of-the-hill radiation-hardening
The goal of radiation hardening is to make a program still work after you remove a byte. However, what if a skilled competitor is purposefully trying to mess with you?
In this game, each bot will take turns removing one character from ...
@emanresuA They're improving. Hitting an Altgr in there, that huge combo multiplier with the |s, and a good randomness entropy in certain places. Soon your cat's gonna be out of the neighborhood keyboard stepping leagues. You better get them a professional trainer.
Okay, emanresu's cat's keyboard smashes were funny the first couple of times, but this room still has rules against posting noise. If, for some reason, you have a bunch of random text in your text box, don't press enter. If, for some reason, something causes a bunch of noise to be typed and posted, please delete it if you have the time to do so.
alternatively: your cat can get its own account and post noise on its own terms (without affecting your rule abiding status)
speaking of random text: are there any studies of keymashing yet? me and some friends are trying to make a lang designed to look like authentic keymashes (and are otherwise generally interested in how they are formed)
id think its only a matter of time anyway
also: i forget but isnt there a challenge about verifying how close to "truly random" some input is?
@Seggan Might be too hard unless the subset is very small but then it's not the JVM anymore and we've had challenges about implementing interpreters for stack-based languages
Carry-less sum given a base b
Note: I'm mostly posting this in the Sandbox because I suspect it might be a dupe but can't find any. But, of course, any input dupe-related or not is welcome.
Given a list of positive integers \$\mathcal I=I_1,I_2,I_3,...,I_n\$ and a base \$b>1\$ return their "carry...