Risolto


Find the stride of the longest skip sequence
We define a _skip sequence_ as a regularly-spaced list of integers such as might be generated by MATLAB's <http://www.mathworks....

circa 14 anni fa

Risolto


Specific toolboxes
Given a string that is the name of a MATLAB toolbox, return true if it is available on the Cody solvers evaluation system, false...

circa 14 anni fa

Risolto


Remove DC
Input x is the sampled signal vector, may have both AC and DC components. Output y should not contain any DC component. Examp...

circa 14 anni fa

Risolto


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

circa 14 anni fa

Risolto


Number of 1s in the Binary Representation of a Number
*Description* Return the number of 1s in the (unsigned integer) binary representation of a number. This function should be ab...

circa 14 anni fa

Risolto


Factorize THIS, buddy
List the prime factors for the input number, in decreasing order. List each factor only once, even if the factorization includes...

circa 14 anni fa

Risolto


Project Euler: Problem 1, Multiples of 3 and 5
If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23...

circa 14 anni fa

Risolto


Roll the Dice!
*Description* Return two random integers between 1 and 6, inclusive, to simulate rolling 2 dice. *Example* [x1,x2] =...

circa 14 anni fa

Risolto


Sum all integers from 1 to 2^n
Given the number x, y must be the summation of all integers from 1 to 2^x. For instance if x=2 then y must be 1+2+3+4=10.

circa 14 anni fa

Risolto


Sorted highest to lowest?
Return 1 if the input is sorted from highest to lowest, 0 if not. Example: 1:7 -> 0 [7 5 2] -> 1

circa 14 anni fa

Risolto


Check if sorted
Check if sorted. Example: Input x = [1 2 0] Output y is 0

circa 14 anni fa

Risolto


radius of a spherical planet
you just measured its surface area, that is the input.

circa 14 anni fa

Risolto


Elapsed Time
Given two date strings d1 and d2 of the form yyyy/mm/dd HH:MM:SS (assume hours HH is in 24 hour mode), determine how much time, ...

circa 14 anni fa

Problema


A stroll on the beach: finding a route round a connected region
You are standing on the beach of an island, which you must explore by walking all the way round its coast. Each step is in one o...

circa 14 anni fa | 1 | 12 risolutori

Risolto


A stroll on the beach: finding a route round a connected region
You are standing on the beach of an island, which you must explore by walking all the way round its coast. Each step is in one o...

circa 14 anni fa

Risolto


Create a function handle that reverses the input arguments of another function handle
Given a function that takes two input arguments and returns one output, create another function handle that performs the same op...

circa 14 anni fa

Risolto


Kaprekar Steps
6174 is the <http://en.wikipedia.org/wiki/6174_%28number%29 Kaprekar constant>. All natural numbers less than 10,000 (except som...

circa 14 anni fa

Risolto


Find the palindrome
Given the string a, find the longest palindromic sub-string b. So when a = 'xkayakyy'; you should return b = 'kayak';

circa 14 anni fa

Risolto


Remove all the consonants
Remove all the consonants in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill'; Output s2 is 'a ...

circa 14 anni fa

Risposto
How to do the image matching?
If you have the Image Processing Toolbox, use *normxcorr2*. In the documentation, "template" means your small image, and "A" is ...

circa 14 anni fa | 0

Risposto
Image Resolution
If you have the Image Processing Toolbox, try *imresize*.

circa 14 anni fa | 0

Risposto
How to find ht:width ratio of a connected component?
Have a look at *regionprops*. It will give you an aspect ratio for each blob, or the bounding box.

circa 14 anni fa | 0

| accettato

Risolto


Prime factor digits
Consider the following number system. Calculate the prime factorization for each number n, then represent the prime factors in a...

circa 14 anni fa

Risolto


Given two strings, find the maximum overlap
Given two strings s1 and s2, create a new string s3 which is as short as possible and contains both strings. If s1 = [1 2...

circa 14 anni fa

Risolto


It dseon't mettar waht oedrr the lrettes in a wrod are.
An internet meme from 2003 (read more <http://www.snopes.com/language/apocryph/cambridge.asp here>) asserted that readers are re...

circa 14 anni fa

Risolto


Knight's Tour Checker
Given a matrix a, determine whether or not a legal <http://en.wikipedia.org/wiki/Knight's_tour knight's tour> is present. The kn...

circa 14 anni fa

Risolto


Mandelbrot Numbers
The <http://en.wikipedia.org/wiki/Mandelbrot_set Mandelbrot Set> is built around a simple iterative equation. z(1) = c z...

circa 14 anni fa

Risolto


Test for balanced parentheses
Given the input inStr, give the boolean output out indicating whether all the parentheses are balanced. Examples: * If ...

circa 14 anni fa

Risposto
What do you think of Cody, new service for MATLAB Central
It would be helpful to know what toolboxes are available to solution code. I'm sure I saw a solution that used a function from t...

circa 14 anni fa | 1

Risolto


What is the next step in Conway's Life?
Given a matrix A that represents the state of <http://en.wikipedia.org/wiki/Conway's_Game_of_Life Conway's game of Life> at one ...

circa 14 anni fa

Carica altro