Relative ratio of "1" in binary number
Input(n) is positive integer number
Output(r) is (number of "1" in binary input) / (number of bits).
Example:
* n=0; r=...
Find matching string from a list of strings
Write a function that returns a string that is a unique match (if it exists) of the string |inStr| from a list of strings |strLi...
13年弱 前
解決済み
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...
13年弱 前
解決済み
Converting Decimal to Binary
Given a decimal number that may include a fractional component, convert it into binary representation. The numbers you are given...
Permute diagonal and antidiagonal
Permute diagonal and antidiagonal
For example [1 2 3;4 5 6;7 8 9] -> [3 2 1;4 5 6;9 8 7]
WITHOUT diag function (and variable n...
13年弱 前
解決済み
Persistent Usage
This Challenge is to implement the Matlab Persistent variable capability.
Given a sequence of Calls to a function return the ...
13年弱 前
解決済み
Encoding Google Maps Polylines
This problem is based on the Google Polyline Encoder algorithm. This is how Google Maps encodes a line for display on a map. You...
13年弱 前
解決済み
Cell Source Index
Suppose that C is a cell array whose elements consist of row vectors of elements of the same type. For example, C could be a ce...
13年弱 前
解決済み
Global usage
This Challenge is to utilize Global variables.
Global variables are risky as the subroutine may inadvertently and unwantingly...
13年弱 前
解決済み
The rabbit problem
Someone discovered that rabbits reproduce at the rate of fibonnaci so you just input the number and it will print the fibonnaci ...
Forward Substitution
Solve a lower triangular linear set of equations as described in the following link: http://www.people.virginia.edu/~teh1m/cody/...