已解决


Cannon Ball
Given g (acceleration due to gravity) and desired altitude x, find the minimum ground velocity of a cannon ball to reach x.

12 years 前

已解决


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

12 years 前

已解决


Longest Divisor Run
Given the vector a, find the longest run of consecutive numbers that can be evenly divided by the same number d where d > 1. ...

12 years 前

已解决


Set the array elements whose value is 13 to 0
Input A either an array or a vector (which can be empty) Output B will be the same size as A . All elements of A equal to 13...

12 years 前

已解决


Choose the best fitting dominoes
You will be given a cell array of nx2 matrices. Choose one row from each matrix. These are the ordered pairs that will be plac...

12 years 前

已解决


Stuff the Board
You have a stack of tiles to put onto an array-like playing board. Each tile has a number (always an integer), and the board var...

12 years 前

已解决


Find Rotated Substring
Given a string s1, find if a rotated version of s1 is present in a second string s2. For example, rotated version of some str...

12 years 前

已解决


Snakes on a plane
Given the dimensions of a 2-d plane, create a matrix where a "snake" of ones occupies the plane from top left to bottom right. ...

12 years 前

已解决


Converting Decimal to Binary
Given a decimal number that may include a fractional component, convert it into binary representation. The numbers you are given...

12 years 前

已解决


edge detection
write a function that gives the indexes of rising or falling edge x is a vector (assume it contains always at least one eleme...

12 years 前

已解决


Is the Point in a Circle?
Check whether a point or multiple points is/are in a circle centered at point (x0, y0) with radius r. Points = [x, y]; c...

12 years 前

已解决


Matrix with different incremental runs
Given a vector of positive integers a (>=0); How does one create the matrix where the ith column contains the vector 1:a(i) poss...

12 years 前

已解决


Convert from Base 10 to base 5
Convert the input number from base 10 into base 5: for example: if a(in base 10)= 5 then a(in base 5)= 10

12 years 前

已解决


Create a matrix X, where each column is a shifted copy of the vector v
Example : in->v = (1:5)'; 1 2 3 4 5 out-> [1 5 4 3 2;2 1 5 4 3;3 2 1 5 4;4 3 2 1 5;5 4 3 ...

12 years 前

已解决


Poker Series 09: IsHighCard
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

12 years 前

已解决


Poker Series 06: isThreeKind
The Poker Series consists of many short, well defined functions that when combined will lead to complex behavior. Our goal is t...

12 years 前

已解决


Convert Hard Drive marketing sizes to actual data sizes
Hard drive sizes are typically marketed using the decimal meaning of prefixes, whereas RAM uses binary meanings. For example: ...

12 years 前

已解决


Convert String to Morse Code
Convert a given string to international <http://en.wikipedia.org/wiki/Morse_code Morse Code> * Strings will only have [A-z], ...

12 years 前

已解决


Remove white space from the string
Remove the white spaces (trailing and leading) from the input variable

12 years 前

已解决


Create One Large Eye of size N x N Quickly?
*<http://en.wikipedia.org/wiki/Aye_(yes) Aye !!!>*

12 years 前

已解决


Double Deal
*Description* Given an input vector _v_, return the first element as the first output, the second element as the second outpu...

12 years 前

已解决


random picture with random colours
write a function which creates a random(x,y) matrix with random RGB colours for example create_pic(5,5) gives us a 3d matrix. ...

12 years 前

已解决


Find best domino orientation
Given a list of pairs, find the orientation they should be placed in a line, such that the sum of the absolute values of the dif...

12 years 前

已解决


Get the area codes from a list of phone numbers
Given a string of text with phone numbers in it, return a unique'd cell array of strings that are the area codes. s = '508-647...

12 years 前

已解决


Spot the rectangle
This problem is related to the <http://bit-player.org/2009/the-17x17-challenge 17x17 challenge>. Given a matrix filled with ones...

12 years 前

已解决


Multiply 2 numbers
Very easy, you just have to multiply 2 numbers but you cannot use the following signs (*, /, - ,^) ,mtimes , times, cross, pro...

12 years 前

已解决


Find the two-word state names
Given a list of states, remove all the states that have two-word names. If s1 = 'Alabama Montana North Carolina Vermont N...

12 years 前

已解决


Read a Soroban Abacus
*Description* The Soroban is the name of the modern Japanese abacus. Information on reading a Soroban can be found <http://we...

12 years 前

已解决


Find state names that start with the letter N
Given a list of US states, remove all the states that start with the letter N. If s1 = 'Alabama Montana Nebraska Vermont Ne...

12 years 前

已解决


Monty Hall
The classic Monty Hall "Let's Make a Deal" final showcase puzzle pits the contestant against three Doors. Behind one Door are dr...

12 years 前

加载更多