Solved


Let's see how peculiar we can get
The task is to multiply two numbers. But do it in the most peculiar possible way.

10 years ago

Solved


Find the biggest digit in a matrix
Write a function to find the biggest digit in a matrix; input -> a matrix output -> a digit For example; [12; 47;...

10 years ago

Solved


Determine the length of a string of characters
Determine the length of a string of characters

10 years ago

Solved


Largest Prime Number
Given a matrix X, find the largest prime number in X.

10 years ago

Solved


Is My Wife Wrong?
Answer the question. (see also <http://www.mathworks.com/matlabcentral/cody/problems/149-is-my-wife-right Problem 149: Is my ...

10 years ago

Solved


Temperature Conversion Utility (Strings)
This is a follow-on problem to <http://www.mathworks.com/matlabcentral/cody/problems/2413-temperature-conversion-utility Problem...

10 years ago

Solved


Temperature Conversion Utility
There are a few problems on Cody regarding temperature conversion (C to K, C to F, F to C), but none include Rankine. Furthermor...

10 years ago

Solved


Mechanical Advantage of a Gear Train
Calculate the mechanical advantage of a gear train. The mechanical advantage of a gear couple is given by MA = T_o/T_i where ...

10 years ago

Solved


Integer to boolean
Write a general function that will create the following conversation; Input is a column vector with integers Output is a b...

10 years ago

Solved


Eight Queens Solution Checker
Write a function to verify whether an arrangement of queens on a chessboard is a valid solution to the classic <http://en.wikipe...

10 years ago

Solved


"Low : High - Low : High - Turn around " -- Create a subindices vector
Let two vectors *lo* and *hi* be given. The job is to create a index vector like so idx = [lo(1):hi(1) lo(2):hi(2) ...]...

10 years ago

Solved


Einsteinium-253 decay
Radioactive Einsteinium-253 has a half-life of 1,768,608 seconds. Given 1000mg of Einsteinium-253 at t=0 days, how much is lef...

10 years ago

Solved


Best Square-Shaped Grid for Subplot
If you have x number of plots, find the optimum 'm' number of rows and 'n' number of columns for subplotting where the overall f...

10 years ago

Solved


Area of a Square
Inside a square is a circle with radius r. What is the area of the square?

10 years ago

Solved


Measure a Special Distance
Given an n-by-2 matrix with positive and negative numbers, return an n-by-n matrix in the manner of the function template.

10 years ago

Solved


FIFA World Cup 2014 : Offside
This problem is about offside rule in football (soccer). Input is a matrix with mostly zeros and a few 1, 2, 3 and 4s. A zer...

10 years ago

Solved


root?
* Given a function 'foo', and a position 'there', find the root near 'there'. * For example: If foo=@sin, and there=3.1, then r...

10 years ago

Solved


Find the logic
There exists one logic in between input and output. Find it (easy math). Example 1: x=13 then y=339; Example 2: x=26...

10 years ago

Solved


Leap Year
According to Gregorian Calender(which is in use now, in many countries),decide whether a given year is a leap year or not. Give...

10 years ago

Solved


last n digit of a power function
Calculate the power of a given a base, exponent. Return the last n digit number. Example 1: base = 3; expo = 8; n = 3; ...

10 years ago

Solved


Simple Past of Regular Verbs
Given a regular verb, return the simple past. Example Input verb = 'to work' Output simple_past = 'worked'

10 years ago

Solved


Permutation
How many different words can be formed using all the letters(together) from a given input word? Input is a string.

10 years ago

Solved


Find the coefficient of a number in scientifc notation
Given a non-negative real number N, find the coefficient C and the exponent E of its scientific notation (N = C 10^E). Note that...

10 years ago

Solved


Sum the elements in either diagonal of a square matrix
Sum the elements of a square matrix that lie on either the major diagonal or anti-diagonal.

10 years ago

Solved


Create a Multiplication table matrix...
Create a product table in this format: P = [ 1 2 3 4 5; 2 4 6 8 10; 3 6 9 12 15; 4 8 12 1...

10 years ago

Solved


Test if two numbers have the same digits
Given two integers _x1_ and _x2_, return |true| if the numbers written with no leading zeros contain the same digits. That is, t...

10 years ago

Solved


Next Higher Power of B
|Given a number _n_ and a base _B_ greater than 1, return the lowest integer power of _B_ that is greater than or equal to _n_. ...

10 years ago

Solved


Mersenne Primes
A Mersenne prime is a prime number of the form M = 2^p - 1, where p is another prime number. For example, 31 is a Mersenne prim...

10 years ago

Solved


Divisors of an integer
Given a number N, return a vector V of all integers that divide N. For example, N = 10 Then V=[1 2 5 10]

10 years ago

Solved


Project Euler: Problem 9, Pythagorean numbers
A Pythagorean triplet is a set of three natural numbers, a b c, for which, a^2 + b^2 = c^2 For example, 3^2 + 4^2 =...

10 years ago

Load more