A résolu


Bit Reversal
Given an unsigned integer _x_, convert it to binary with _n_ bits, reverse the order of the bits, and convert it back to an inte...

environ 2 mois il y a

A résolu


Given an unsigned integer x, find the largest y by rearranging the bits in x
Given an unsigned integer x, find the largest y by rearranging the bits in x. Example: Input x = 10 Output y is 12 ...

environ 2 mois il y a

A résolu


Binary numbers
Given a positive, scalar integer n, create a (2^n)-by-n double-precision matrix containing the binary numbers from 0 through 2^n...

2 mois il y a

A résolu


Find out sum and carry of Binary adder
Find out sum and carry of a binary adder if previous carry is given with two bits (x and y) for addition. Examples Previo...

2 mois il y a

A résolu


Convert given decimal number to binary number.
Convert given decimal number to binary number. Example x=10, then answer must be 1010.

2 mois il y a

A résolu


Find the longest sequence of 1's in a binary sequence.
Given a string such as s = '011110010000000100010111' find the length of the longest string of consecutive 1's. In this examp...

2 mois il y a

A résolu


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

2 mois il y a

A résolu


Clueless - Lord Ned in the Game Room with the Technical Computing Language
[Warning: this is a nontrivial programming problem] Worried about the decline in reasoning skills in the clueless populace of...

2 mois il y a

A résolu


Popular Word Game™ Distance
Professor Ned, who holds the Nedowed Chair of Crackpot Mathematics at the University of Nedsburg, has recently discovered the da...

2 mois il y a

A résolu


Who Holds the Lord Ned Challenge Shield?
During the Nedball Premier League regular season, each of the n teams plays each of the other (n-1) teams twice, once at home an...

2 mois il y a

A résolu


The Bridges of Nedsburg
The fabled city of Nedsburg consists of several islands connected by bridges. Due to tectonic forces, shoddy civil engineering, ...

2 mois il y a

A résolu


Is my wife right?
Regardless of input, output the string 'yes'.

2 mois il y a

A résolu


A Nedlish Country Garden - Check for Valid Arrangement
Nedland is famous for its stately gardens, which typically have a centerpiece of a square grid, with certain squares featuring a...

2 mois il y a

A résolu


Average Number of Moves for the Royal Game of Err
Bored of tedious court assemblies, King Neduchadneddar the Procrastinator has found a cunning way to keep his advisors, councilo...

2 mois il y a

A résolu


Transition Matrix for the Royal Game of Err
Bored of tedious court assemblies, King Neduchadneddar the Procrastinator has found a cunning way to keep his advisors, councilo...

2 mois il y a

A résolu


Convert Decimal to Hexavigesimal
NASA (Ned’s Alien-Spying Agency) have made contact with a 13-fingered race from the planet Genai. Naturally, Ned’s shadowy opera...

2 mois il y a

A résolu


Convert Hexavigesimal to Decimal
NASA (Ned’s Alien-Spying Agency) have made contact with a 13-fingered race from the planet Genai. Naturally, Ned’s shadowy opera...

2 mois il y a

A résolu


Government of the Neds, by the Neds, for the Neds - Distribute the Nedsburg City Councilors
The city of Nedsburg consists of several islands, the number of which changes regularly, due to tectonic forces, shoddy civil en...

2 mois il y a

A résolu


Create a cell array out of a struct
Create a cell array out of a (single) struct with the fieldname in the first column and the value in the second column: in: ...

5 mois il y a

A résolu


Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

5 mois il y a

A résolu


Is the Point in a Triangle?
Check whether a point or multiple points is/are in a triangle with three corners Points = [x, y]; Triangle = [x1, y1; x2, y...

10 mois il y a

A résolu


Height of a right-angled triangle
Given numbers a, b and c, find the height of the right angled triangle with sides a and b and hypotenuse c, for the base c. If a...

10 mois il y a

A résolu


Find the sides of an isosceles triangle when given its area and height from its base to apex
Find the sides of an isosceles triangle when given its area and the height from its base to apex. For example, with A=12 and h=...

10 mois il y a

A résolu


Can we make a triangle?
Given three positive number, check whether a triangle can be made with these sides length or not. remember that in a triangle su...

10 mois il y a

A résolu


Right Triangle Side Lengths (Inspired by Project Euler Problem 39)
If p is the perimeter of a right angle triangle with integral length sides, { a, b, c }, there are exactly three solutions for p...

11 mois il y a

A résolu


Calculate the area of a triangle between three points
Calculate the area of a triangle between three points: P1(X1,Y1) P2(X2,Y2) P3(X3,Y3) these three points are the vertices of ...

11 mois il y a

A résolu


Find my daddy long leg (No 's')
Given the ratio of the two legs (longer / shorter), and the hypotenuse length, find the value of the bigger leg.

11 mois il y a

A résolu


Estimating Monthly Electricity Cost for a Household Appliance
You recently bought an electric kettle for your kitchen, and you want to estimate how much it costs to run every month. The kett...

11 mois il y a

A résolu


Voltage Divider Calculation
A voltage divider is a simple circuit used to obtain a reduced voltage from a higher voltage source using two resistors in serie...

11 mois il y a

A résolu


LED Current Calculation
In an electrical circuit, the current (III) flowing through an LED is determined using Ohm’s Law: ​​ Where: I is the current ...

11 mois il y a

Charger plus