King and Four Sons

Cerinta completa The King of Byteland wants to grow his territory by conquering other countries. To prepare his heirs for the future, he decides they must work together to capture each country. The King has an army, , of battalions;

Jim and the Orders

Cerinta completa Jim’s Burgers has a line of hungry customers. Orders vary in the time it takes to prepare them. Determine the order the customers receive their orders. Start by numbering each of the customers from to , front of

Greedy Florist

Cerinta completa A group of friends want to buy a bouquet of flowers. The florist wants to maximize his number of new customers and the money he makes. To do this, he decides he’ll multiply the price of each flower

Grading Students

Cerinta completa HackerLand University has the following grading policy: Every student receives a in the inclusive range from to . Any less than is a failing grade. Sam is a professor at the university and likes to round each student’s

Fun Game

Cerinta completa Kyle and Mike are bored on a rainy day and decide to pass the time by creating a new game having the following rules: The game starts with two -sized integer arrays, and , and is played by

Flipping bits

Cerinta completa You will be given a list of 32 bit unsigned integers. Flip all the bits ( and ) and return the result as an unsigned integer. Example . We’re working with 32 bits, so: Return . Function Description

Fighting Pits

Cerinta completa Meereen is famous for its fighting pits where fighters fight each other to the death. Initially, there are fighters and each fighter has a strength value. The fighters are divided into teams, and each fighter belongs exactly one

Encryption

Cerinta completa An English text needs to be encrypted using the following encryption scheme. First, the spaces are removed from the text. Let be the length of this text. Then, characters are written into a grid, whose rows and columns

Decibinary Numbers

Cerinta completa Let’s talk about binary numbers. We have an -digit binary number, , and we denote the digit at index (zero-indexed from right to left) to be . We can find the decimal value of using the following formula: