Solved


Easy Sequences 52: Non-squarable Rectangles
Any integer-sided rectangle can be cut into unit rectangles () and rearranged into sets of smaller rectangles. For example the ...

2 years ago

Solved


Return area of square
Side of square=input=a Area=output=b

2 years ago

Solved


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

2 years ago

Solved


Calculate Amount of Cake Frosting
Given two input variables r and h, which stand for the radius and height of a cake, calculate the surface area of the cake you n...

2 years ago

Solved


Five-dimensional maze
*Description* The traditional maze is 2-dimensional: the navigator can move in the positive or negative directions along two ...

2 years ago

Solved


One track five lanes
Find the minimum number of lane changes necessary to cross the entire track without running into any obstacles <<http://www.a...

2 years ago

Solved


Parse me a Lisp
*Description* In Lisp and its variants, function calls are done using parenthesis where the first item in the parenthesis is ...

2 years ago

Solved


Recaman Sequence - III
I want to create a Recaman sequence where there is a "1" in the n-th position. So from which integer should I start the Recaman ...

3 years ago

Solved


Pair Primes
Let's define pair primes as follow; For 2 digits numbers: 11 and 17 are pair primes because both of them are 2 digits prime num...

3 years ago

Solved


Birthday cake
It's Cody's 5th birthday, and you've been tasked with putting the candles on the cake. Your goal is to maximize the distance bet...

3 years ago

Solved


Day counter function
Write a function called _day_counter_ that returns the number of Mondays that fell on the first day of the month in a given year...

3 years ago

Solved


Decimation
When dealing to the Roman Army, the term decimate meant that the entire unit would be broken up into groups of ten soldiers, and...

3 years ago

Solved


Odd elimination
Inspired by Project Euler problem #539 You'll be given a vector from 1 to n; Going from left to right, remove the first n...

3 years ago

Solved


Pandigital Multiples of 11 (based on Project Euler 491)
A "Pandigital number of order X" is one that contains all of the numbers from 0 to X, but with no leading zeroes. If X>9, the cy...

3 years ago

Solved


Project Euler 249: Prime Subset Sums
Inspired by Problem 249 of Project Euler. <https://projecteuler.net/problem=249> Let S = {2, 3, 5, ...} be the set of prime ...

3 years ago

Solved


Easy Sequences 49: Prime Little Omega Function
For an integer , the prime little omega function, , is defined as the total number of distinct prime factors of . So, if , sinc...

3 years ago

Solved


Easy Sequences 48: Prime Big Omega of Factorial Sequence
For an integer , the prime big omega function, , is defined as the total number of prime factors of . So, if , since , therefor...

3 years ago

Solved


Easy Sequences 47: Boxes with Prime Edges
This is related to problem "Easy Sequences 41: Boxes with Integer Edges". However, here we will be investigating a smaller-sized...

3 years ago

Solved


Easy Sequences 46: Semi-prime Leap Year Pairs
A semi-prime is a positive integer that has only and exactly prime factors. Here is a list of the first few semi-primes:. We...

3 years ago

Solved


Easy Sequences 45: Second Derivative of Inverse Polynomial Function
The inverse of a function, is the function , that reverses . That means that if , then . For example, the function to convert ce...

3 years ago

Solved


Easy Sequences 44: Finding the Smallest Number whose Cube is divisible by a Factorial
Given a integer , our goal is to find the smallest integer , such that divides . For example, for , , because , (since ), and ...

3 years ago

Solved


Easy Sequences 42: Areas of Non-constructible Polygons
A constructible polygon is a regular polygon that can be constructed using only a compass and a straightedge. Amazingly, Gauss ...

3 years ago

Solved


Easy Sequences 41: Boxes with Integer Edges
For this problem, we are asked to write a function that will count the number of boxes with integer edges, that has the same giv...

3 years ago

Solved


Easy Sequences 39: Perfect Squares in Pascal's Triangle
Consider the 2nd, 3rd and 4th diagonals of the Pascal's Triangle, shown highlighted below: ...

3 years ago

Solved


Easy Sequences 38: Prime Number Delta
The Prime Number Theorem states that: where is the prime counting function (number of pri...

3 years ago

Solved


Sum the elements in rows of the Levine triangle
The Levine triangle starts as follows: Row 0: 2 Row 1: 1 1 Row 2: 1 2 Row 3: 1 1 2 To construct each row, r...

3 years ago

Solved


Fill a rectangle with 1x1 and 2x2 tiles
A 3x2 rectangle can be filled with 1x1 and 2x2 tiles in three ways: The colors merely distinguish the sizes of the tiles. A 3...

3 years ago

Solved


Count the ways to draw non-intersecting chords between points on a circle
There are 9 ways to draw non-intersecting chords between four points on the perimeter of a circle (including no chords at all). ...

3 years ago

Solved


Count unique orderings of vertices of a polygon
Cody Problem 2671 asks us to determine whether four points can be the corners of a rectangle. The points are not necessarily inp...

3 years ago

Solved


Classify product/digit-sum sequences
Cody Problem 53120 involved a sequence in which a term is computed by multiplying the previous two terms and adding the digits o...

3 years ago

Load more