Solved


Add more zeros
Find code that adds one 0 to each sequence of 0 in a string (composed with only 0 or 1). For example: '1010' -> '100100' ...

8 years ago

Solved


Reverse the Words (not letters) of a String
*Description* Change the words of a string such that the words appear in reverse order. You may assume that the string is a n...

8 years ago

Solved


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

8 years ago

Solved


Make a 1 hot vector
Make a vector of length _N_ that consists of all zeros except at index _k_, where it has the value 1. Example: Input ...

8 years ago

Solved


Calculate a modified Levenshtein distance between two strings
Inspired by the Cody problem found <http://www.mathworks.com/matlabcentral/cody/problems/93-calculate-the-levenshtein-distance-b...

8 years ago

Solved


Without the French accent please!
Suppress the French accent. Example 'Déjà présent' -> 'Deja present'

8 years ago

Solved


Use of regexp
Given a string, containing several sentences, such as: 'I played piano. John played football. Anita went home. Are you safe?...

8 years ago

Solved


Convert a structure into a string
Convert the contents of each fields into a string. Example with an input structure s with 2 fields : s.age = '33' s....

8 years ago

Solved


Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise

8 years ago

Solved


Is A the inverse of B?
Given a matrix A and a matrix B, is A the inverse of B? >>A=[2,4;3,5]; >>B=[-2.5,2;1.5,-1]; >>isInverse...

8 years ago

Solved


Convert a vector into a number
This is a sub problem related to this problem: <http://www.mathworks.com/matlabcentral/cody/problems/621-cryptomath-addition>...

8 years ago

Solved


Get the length of a given vector
Given a vector x, the output y should equal the length of x.

8 years ago

Solved


Find the sum of the elements in the "second" diagonal
Find the sum of the elements in the diagonal that starts at the top-right corner and ends at the bottom-left corner.

8 years ago

Solved


Sum of diagonal of a square matrix
If x = [1 2 4; 3 4 5; 5 6 7] then y should be the sum of the diagonals of the matrix y = 1 + 4 + 7 = 12

8 years ago

Solved


inner product of two vectors
inner product of two vectors

8 years ago

Solved


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

8 years ago

Solved


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

8 years ago

Solved


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for. Examples: fin...

8 years ago

Solved


Weighted average
Given two lists of numbers, determine the weighted average. Example [1 2 3] and [10 15 20] should result in 33.333...

8 years ago

Solved


Will there be a new leader?
Simply answer the title.

8 years ago

Solved


Compress strings (not springs)
Please remove excess space, limit one space between others, and no space before punctuation marks. * For example, 'Trendy , ...

8 years ago

Solved


Return median of a matrix
Compute median of a matrix of any dimension. Exclude the NaNs if any.

8 years ago

Problem


Return median of a matrix
Compute median of a matrix of any dimension. Exclude the NaNs if any.

8 years ago | 0 | 73 solvers

Solved


Basic matlab numeric and string manipulations
If entered input (n) is _numeric_ , compute its *log to the base (n+2)* , if it is a _lower case_ alphabet, *convert it to i...

8 years ago

Problem


Basic matlab numeric and string manipulations
If entered input (n) is _numeric_ , compute its *log to the base (n+2)* , if it is a _lower case_ alphabet, *convert it to i...

8 years ago | 0 | 41 solvers

Solved


Check for keywords
If the entered string is a MATLAB keyword, return true else false

8 years ago

Problem


Check for keywords
If the entered string is a MATLAB keyword, return true else false

8 years ago | 1 | 61 solvers

Solved


Product of all elements in an array
Compute the product of all elements in an array.

8 years ago

Problem


Product of all elements in an array
Compute the product of all elements in an array.

8 years ago | 1 | 94 solvers

Solved


generate capital english alphabets
Based on the numeric input 'n', generate the capital english alphabet starting from A till the english alphabet at the 'n'th pos...

8 years ago

Load more