Discussion


Check out Cody problems created by minnolina
As of August 2026, there are over 5,700 problems on Cody. Given that large quantity, and how long the site has been around, you ...

3 months ago | 0

Solved


Connect Four - 01
Connect four is a two player board game. <https://en.wikipedia.org/wiki/Connect_Four> Given a complete connect-four board,...

3 months ago

Solved


First Duplicate
Given an array of integers, return the first duplicate — i.e., the element that appears more than once and whose second appearan...

3 months ago

Solved


Zero
given an integer a, find the smallest possible integer b(b>0) such that their bitwise logical AND is zero. * if a=11(1011) t...

3 months ago

Solved


Pascal's Pyramid - A Variation with an Arial View
Let's create a matrix of size N x N containing a Pascal's Triangle in each quadrant that diverges from the centre to form an ari...

3 months ago

Solved


Pascal's Triangle
Create a matrix of size N x N containing a Pascal's Triangle that starts from the upper left corner according to the test cases ...

3 months ago

Solved


Fibonacci Word
F1='0' F2='1' F3 is the catenation of the previous two. So, F3 = cat(F2,F1)='10'. similarly, F4 = cat(F3,F2)= '101' ...

3 months ago

Solved


Unique rows
A matrix is given as the input. Remove any duplicate rows from the matrix. keep the first occurrence.

3 months ago

Solved


Steering 101-Ackermann Steering Ratio
In a turning vehicle, inner and outer wheels follow different radii. Ackermann steering geometry ensures both wheels roll withou...

3 months ago

Solved


Secret Message and Acrostic
One of the simplest ways to hide a message involves utilizing uppercase letters. Given a text, collect all uppercase letters in...

3 months ago

Solved


Integer Persistence, Product
Let's construct a sequence as follows: is a given natural number, and is the product of the digits of . The persistence of i...

3 months ago

Solved


Calculating the Union Area of Overlapping Rectangles
Calculate the area covered by a union of multiple rectangles. Each rectangle is represented by 4 integers: the first two integer...

3 months ago

Solved


Perfect shuffle
We call "perfect shuffle" the process of cutting a deck of cards into two equal halves, and then perfectly interleaving them: on...

3 months ago

Solved


Available ingredients + recipe -> number of cakes
Write a function Egg_Milk_Sugar(L, recipe) to determine the maximum number of cakes that can be prepared given a list of availab...

3 months ago

Solved


Sun angle
Determine the angle of the sun above the horizon based on the time of day. Assumptions: the sun rises in the East at 6h00, cor...

3 months ago

Solved


Maximizing Stock Profit
As a stock exchange broker focusing on a single transaction, your goal is to maximize profit by buying a stock at a low price an...

3 months ago

Solved


Hofstadter H sequence
The Hofstadter H sequence is defined as follows: The first elements of the sequence are 0, 1, 1, 2, 3, 4, 4, 5, 5, 6. Write ...

3 months ago

Solved


Hofstadter G sequence
The Hofstadter G sequence is defined as follows: The first elements of the sequence are 0, 1, 1, 2, 3, 3, 4, 4, 5, 6. Write ...

3 months ago

Solved


Reversing Maximal Ascending Subsequences
Create and return a new array that contains the same elements as the input array, but with the elements within each strictly inc...

3 months ago

Solved


Limiting Element Occurrences
You are given a list 'v' of numbers. This list may contain repeated numbers. Your objective is to create a new list that maintai...

3 months ago

Solved


Stern-Brocot Sequence
The Stern-Brocot diatomic sequence is defined as follows: The first elements of the sequence are 0, 1, 1, 2, 1, 3, 2, 3, 1, 4...

3 months ago

Solved


Counting the occurrences of a digit in a book
The printer has printed a book with 'p' pages. How many times did they use the character 'd'? In other words, how many times doe...

3 months ago

Solved


Absolute Sorting
Given an array with various numbers, your have to sort it by absolute value in ascending order. For example, for the array [-2...

3 months ago

Solved


Compress list
Given a non-empty list L of positif integers, compress the list so that only one occurrence is retained if two (or more) equal e...

3 months ago

Solved


Pronounce digits
Given a number num, select the first d decimal places and pronounce the digits (in English). The function returns the pronunciat...

3 months ago

Solved


Spreadsheet Column Number
Spreadsheet uses an alphabetic naming system for columns, starting with 'A', 'B', 'C', etc. The column names continue like 'AB',...

3 months ago

Solved


Pivot index
Let L be a vector of numbers. We are searching for the index n of the pivot element defined as follows: the dot product of the e...

3 months ago

Solved


Interval Compression
Given a set of integers, the task is to create a list of closed intervals where each interval includes its endpoints. For exampl...

3 months ago

Solved


Final Stone Weight
You are given an array with weights of stones. The objective is to determine the weight of the final stone remaining after all c...

3 months ago

Solved


Leader
An element of a list is called a "leader" if every element to its right (and not just the one immediately to its right) is stric...

3 months ago

Load more