Solved


Remove the small words from a list of words.
Your job is to tidy up a list of words that appear in a string. The words are separated by one or more spaces. Remove all words ...

5 years ago

Solved


Least common multiple of many numbers
1:6 -> 60

5 years ago

Solved


vectorization in N
For a given integer n (n>1), compute the sum f (i) (1 <= i <= n) where f (i) = 1 if n is odd and 2 otherwise.

5 years ago

Solved


Count ones
Write a program to count number of ones (1s) in an integer variable input. For example: Input x=2200112231 output y=3 I...

5 years ago

Solved


Evaluate Polynomial
Given a polynomial equation coefficients in a vector p, you have to return its value at x. Example: For inputs p and x ...

5 years ago

Solved


Polynomial Multiplication
Multiply two polynomial equation.Given polynomial coefficients a and b.

5 years ago

Solved


Negative Infinity
Round the given array a towards negative infinity.

5 years ago

Solved


Roots
Find out the roots of a given polynomial equation.Given are the coefficients of the equation.

5 years ago

Solved


Magic!
Check whether the input matrix is a normal magic square: <http://en.wikipedia.org/wiki/Magic_square> Output the logical va...

5 years ago

Solved


Back to basics 25 - Valid variable names
Covering some basic topics I haven't seen elsewhere on Cody. Given a string, return true if it is a valid MATLAB variable nam...

5 years ago

Solved


Matlab Basics II - Extract last 3 elements of a vector
Let x be a vector of unknown length, we are always interested in the last 3 numbers in the vector, write a function that gives t...

5 years ago

Solved


find the answer

5 years ago

Solved


Perimeter of a Triangle

5 years ago

Solved


find the answer

5 years ago

Solved


Surface area of a cone

5 years ago

Solved


find the value

5 years ago

Solved


Volume of a sphere

5 years ago

Solved


find the answer

5 years ago

Solved


find the answer

5 years ago

Solved


Volume of cone

5 years ago

Solved


area of a sphere

5 years ago

Solved


Sort a vector

5 years ago

Solved


Make blocks of color
Given a (Nx3) sequence of RGB colors, I want to create a (numRowBlocks x numColBlocks x 3) image comprising (blockSize x blockSi...

5 years ago

Solved


RGB to CMYK
Convert an RGB code to the corresponding CMYK code for printing. The RGB input is a [1×3] double array between 0 and 1. ...

5 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...

5 years ago

Solved


Project Euler: Problem 16, Sums of Digits of Powers of Two
2^15 = 32768 and the sum of its digits is 3 + 2 + 7 + 6 + 8 = 26. What is the sum of the digits of the number 2^N? Thanks ...

5 years ago

Solved


Hexagonal numbers on a spiral matrix
Put hexagonal numbers in a ( m x m ) spiral matrix and return the sum of its diagonal elements. Formula of hexagonal numbers ...

5 years ago

Solved


Nilpotent matrix
Check if matrix A is <http://mathworks.com/ nilpotent>.

5 years ago

Solved


Orthonormal matrix
You decide whether any given matrix is an orthonormal matrix or not. If each column in a matrix is perpendicular to the other...

5 years ago

Solved


Combined Ages 1 - Symmetric, n = 3
You have probably seen the common riddle wherein combined ages are provided and you must determine the individual ages. For exam...

5 years ago

Load more