已解决


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

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

7 years 前

已解决


ABBREVIATION
Abbreviate the given string. Consider Only Capital Letters. EXAMPLE If input is 'Abbreviation of The Given String' then ou...

7 years 前

已解决


Now 20% off!
Furloughs are hitting government workers this year. To commemorate getting one unpaid day off each week until the end of Septem...

7 years 前

已解决


Divisible by 6
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

7 years 前

已解决


Divisible by 5
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

7 years 前

已解决


Divisible by 3
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

7 years 前

已解决


Divisible by 4
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...

7 years 前

已解决


Divisible by 2
This is the first problem in a set of "divisible by x" problems. You will be provided a number as a string and the function you ...

7 years 前

已解决


Project Euler: Problem 4, Palindromic numbers
A palindromic number reads the same both ways. The largest palindrome made from the product of two 2-digit numbers is 9009 = 91 ...

7 years 前

已解决


Rosenbrock's Banana Function and its derivatives
Write a function to return the value of <http://en.wikipedia.org/wiki/Rosenbrock_function Rosenbrock's two-dimensional banana fu...

7 years 前

已解决


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

7 years 前

已解决


How unique?
Sometimes, when we check unique entries of vector we would like to know how many times each value occurs. Given vector of num...

7 years 前

已解决


Max Change in Consecutive Elements
If an array is given as input then find the index of consecutive elements that represent maximum change. Example: Input ...

7 years 前

已解决


counting groups!
This problem is about counting groups. Example If you have x: x = [0.8 0.8 0.8 0.3 0.3 0.4 0.5 0.6 0.6 0.9] then a...

7 years 前

已解决


Another colon problem
This is simple problem based on problems 555, 801, 1118, etc. Create an index vector from two input vectors. Example: ...

7 years 前

已解决


Piecewise linear interpolation
Given an Mx2 vector and a row of M-1 integers, output a two column vector that linearly interpolates Y times between each succes...

7 years 前

已解决


Calculate Euler's phi function
Compute the Euler's phi function of a large integer. For more information about this topic please visit: <https://en.wikiped...

7 years 前

已解决


Mirror Image matrix across anti-diagonal
Given an input number x, create a mirror image matrix 'Y' across the anti-diagonal. For example, if x=3, Y = [1 2 3; ...

7 years 前

已解决


Calendar Matrix
Return a calendar matrix for the given values of month and year. Assume that Sunday is the first day of the week. The resulting ...

7 years 前

已解决


Triangular matrices in 3D array
Given a 3D numeric array _x_, return an array _y_ of the same size in which all entries to the right of the main diagonal are ze...

7 years 前

已解决


Bullseye Matrix
Given n (always odd), return output a that has concentric rings of the numbers 1 through (n+1)/2 around the center point. Exampl...

7 years 前

已解决


Create a block diagonal matrix
A block diagonal matrix is a square matrix that can be written as A = [a 0 0 0 0 b 0 0 0 0 c 0 ...

7 years 前

已解决


Toeplitz Matrix
For a given square matrix of order n-by-n check whether this is a Toeplitz matrix or not. Return true if it is.

7 years 前

已解决


Generate this matrix
For a given odd integer n, generate a matrix as follows: Input: n = 5; Output: [ 2 1 0 0 0 1 ...

7 years 前

已解决


ZigZag matrix with reflected format
ZigZag MATRIX with REFLECTED format. We have only input x. We have to create a matrix in the following pattern. input n=5...

7 years 前

已解决


Numbers spiral diagonals (Part 1)
Inspired by Project Euler n°28 et 58. A n x n spiral matrix is obtained by starting with the number 1 and moving to the right...

7 years 前

已解决


Rainbow matrix
Create a "rainbow matrix" as described in the following examples Input = 3 Output = [ 1 2 3 2 3 2 ...

7 years 前

已解决


Generate this matrix
Generate the following matrix. n = 2; out = [-4 -3 -2 -1 0 -3 -2 -1 0 1 -...

7 years 前

已解决


Combine the first and last names
MATLAB R2016 provides a rich set of functions to work with string arrays. In this problem, you will be given two string arrays o...

7 years 前

加载更多