About a year ago I found a tool that would try to guess how to decrypt a ciphertext using about 5-10 popular algorithms and pick the answer that looks the most like English after it put enough effort into it
Fillomino is a puzzle where you fill a grid with polyominoes. Each polyomino is an area of contiguous cells. The grid representation shows what size polyomino is covering each cell. For example, a pentomino(5) would be shown as 5 in each of five contiguous cells (see below). Two polyominoes of th...
I have a for loop which goes through an array but I am trying to restrict it to break after the 2nd item.
var x="",i=0;
for (var x in marking;i=0;i++) {
if (i==2){
break;
}
index.push(marking[x]);
};
The console log error
SyntaxError: missing ) after for-loop control
f...
I was saying that even CoffeeScript can't provide identical syntax for accessing objects and arrays, since it's a compile-time-only transformation (and can't introspect the type of the object), but they have a nice alternative to that.
The Kolmogorov complexity of a string s is defined as the length of the shortest program P that outputs s. If the length of P is shorter than the length of s, then s is said to be compressible, otherwise s is incompressible. Most strings are incompressible ...
Write the shortest program that out...
Hey guys i am a web designer. I am a total newbie to programming.
i want to ask that is it OK to start learning javascript or should I go for any other language to get my programming concepts strong before learning javascript?
thanks.
To be honest, I'm not sure I'm a big fan of these bot notifications in this chat room (as opposed to the GolfEye chat room). I'm not saying my word is law, but I just wanted to raise an opinion.
@Chris Meh, questions are so rare here that it's uncommon enough to not be a disturbance. And this way more people are aware of the bot in the first place. You can always ignore the bot if it bothers you too much. And I feel that encouraging people to review and evaluate posts as they are posted will be good for the site's health as a whole. /cc @PeterTaylor
Fair enough. Reminds me of sobot (a bot in #stackoverflow that broadcast new questions on Stack Overflow, back in the days when new questions were infrequent).
Since the traffic on SO is way too high now, sobot is no longer running.
Challange
Write a program that calculates all the prime numbers and prints them to the screen. The smallest program wins of cource. It has to continue for ever (or integer overflow).
Note that it is not allowed to use a built in function if your langue has one.
This problem idea is borrowed from a recent Croatian programming contest but please don't cheat by looking at the solution outlines :) You are given a set of circles in the plane with their centers on the line y = 0:
It is guaranteed that no pair of circles has more than one common point.
You...
What do you guys think: would it be valid (for golfing) to create my own version of python, with a lot of names shortened and things already imported (if the "compiler" were open-source, anyone could use it, blabla)?