Source: Squares With Three Sides
Part 1: Given a list of sides, determine how many form valid triangles. (Hint: triangle inequality)
Part 1: Given a list of sides, determine how many form valid triangles. (Hint: triangle inequality)
Part 1: Starting at
0,0
and given a string ofL#
/R#
to turn left / right and move#
squares, where do you end up?
Part 1: Take the relation:
Arrange the values according to Cantor's diagonal argument. Find the value at a specific cell.
Part 1: Split a list of integers into three groups of equal sum. Find the grouping such that the smallest group has the least items, breaking ties by the smallest product for that group.
Part 1: Create a simple virtual machine with two registers (a
and b
, non-negative integers) and six instructions:
hlf (a|b)
- divide the given register by half, round downtpl (a|b)
- triple the given registerinc (a|b)
- add 1 to the given registerjmp [+-]\d+
- jump forward/backwards by the given number of instructionsjie (a|b), [+-]\d+
- if the given register is even, jumpjio (a|b), [+-]\d+
- if the given register equals one, jumpPart 1: Simulate an RPG mage battle; finding the winning solution using the least mana. See the original writeup for more details.
Part 1: Given a shop full of weapons (buy exactly one), armor (buy zero or one), and rings (buy 0, 1, or 2), determine the set of items that will defeat a given enemy for the minimum cost (see the original writeup for more details).
Part 1: P(n) is defined such that for each number i, add 10i to any number divisible by i. Find the first value n such that P(n) is at least a given target number.
Part 1: Given a list of list of string replacements and an input string, determine how many unique output strings are possible after one step.