Solved

Weird Diagonal Matrix!!

Given an integer n, create a matrix whose diagonal elements will be square matrices of size 1 to n. For example: n=2 z = ...

2 months ago

Solved

Mean number of letters per word (Hard)

The previous problem in this series is <https://www.mathworks.com/matlabcentral/cody/problems/44852-mean-number-of-letters-per-w...

2 months ago

Solved

Segmented number sequence

Given a positive integer, n, and a row vector, x, of positive integers, return a row vector, v, which is a sequence of length n ...

2 months ago

Solved

Aztec Diamond domino tilings

Consider a Cartesian grid, with verteces at integer x and y values, where every four vertices around a vacant space define a uni...

2 months ago

Solved

Return the sequence element I

Given a positive integer, x, return a positive integer, y, which is the xth term in the sequence [1 2 2 3 3 3...], in which one ...

2 months ago

Solved

Factorizing a number into a given number of factors

Given a positive integer, n, and another positive integer, b, return a matrix, M, of width b, with the following properties: (a)...

2 months ago

Solved

Vector multiplication

Given two row vectors, v1 and v2, each representing an integer, such that the vector elements are the digits from left to right,...

2 months ago

Solved

Increasing sub-sequence (Level 1)

Given a vector, v, of real numbers, return a positive integer, n, representing the longest contiguous increasing sub-sequence co...

2 months ago

Solved

Britney unfolded

You have a long, narrow strip of paper. You are going to fold this strip of paper length-wise in half, than fold the folded stri...

2 months ago

Solved

Juggler sequence revisited

This problem is related to <http://www.mathworks.com/matlabcentral/cody/problems/42835-return-the-sequence-element-ii Problem 42...

2 months ago

Solved

Polygon division

Given the number of vertices (or sides), n, of a planar convex polygon, return the number of ways, w, in which you can divide th...

2 months ago

Solved

Identify the sequence

Given a row vector, x, return 1 if it is an arithmetic series, or 2 if it is a geometric series. If it is neither, return 0. ...

2 months ago

Solved

Vector addition

Given two row vectors, v1 and v2, each representing an integer, such that the vector elements are the digits from left to right,...

2 months ago

Solved

Regular polygon bounded by and bounding a circle

As the number of sides (or vertices) of a regular polygon goes to infinity, its perimeter and area go to the perimeter and area ...

2 months ago

Solved

Define an arithmetic sequence

Given three numbers n, a, and d, define an arithmetic sequence of n terms with a being the initial term of the sequence and d be...

2 months ago

Solved

Find the slope of a line that passes through two vectors

Given two vectors p1 and p2, return the slope of a line that passes through p1 and p2. Examples: Input [p1,p2] = deal([0,1],[...

2 months ago

Solved

String Logic 19

Examples: 'DIG' --> 'I' 'IMPORTANT' --> 'MOTN' 'DEAL' --> 'EL' 'LIMB' --> 'IB' 'MOSTLY' --> 'OTY'

3 months ago

Solved

String Logic 18

Examples: 'DIG' --> 'DG' 'IMPORTANT' --> 'IPRAT' 'DEAL' --> 'DA' 'LIMB' --> 'LM' 'MOSTLY' --> 'MSL'

3 months ago

Solved

String Logic 16

Examples: 'DIG' --> 'DIG' 'KIMBALL' --> 'ALLKIMB' 'DEAL' --> 'EALD' 'LIMB' --> 'IMBL' 'MADE' --> 'ADEM'

3 months ago

Solved

String Logic 17

Examples: 'DIG' --> 'GDI' 'IMPORTANT' --> 'TANTIMPOR' 'DEAL' --> 'EALD' 'LIMB' --> 'IMBL' 'MOSTLY' --> 'YMOSTL'

3 months ago

Solved

String Logic 15

Examples: 'CAT' --> 'XZG' 'DOG' --> 'WLT' 'ROSY' --> 'ILHB' 'MOSTLY' --> 'NLHGOB'

3 months ago

Solved

String Logic 14

Examples: 'DIG' --> 'HRN' 'KIMBALL' --> 'VRZDBXX' 'DEAL' --> 'HJBX' 'LIMB' --> 'XRZD' 'MADE' --> 'ZBHJ' 'CHEF' --> 'FPJL'

3 months ago

Solved

String Logic 13

Examples: 'CAT' --> 'TCA' 'DOG' --> 'OGD' 'ROSY' --> 'YSRO' 'MOSTLY' --> 'YTSOML'

3 months ago

Solved

String Logic 12

Examples: 'CAT' --> 'ACT' 'DOG' --> 'DGO' 'ROSY' --> 'ORSY' 'MOSTLY' --> 'LMOSTY'

3 months ago

Solved

String Logic 10

Examples: 'SUNDAY' --> 83 'MONDAY' --> 77 'TUESDAY' --> 84 'WEDNESDAY' --> 87 'THURSDAY' --> 84 'FRIDAY' --> 70 'SATURD...

3 months ago

Solved

String Logic 9

Examples: 'CAT' --> 'C' 'DOG' --> 'G' 'ROSLY' --> 'R' 'PROBLEM' --> 'M' 'TRUST' --> 'T' 'BASIC' --> 'C' 'GIANT' --> 'I'...

3 months ago

Solved

String Logic 8

Example: 'CAT' --> 65 'DOG' --> 68 'ROSY' --> 79 'MATLAB' --> 65 'TRUST' --> 82 'MOSTLY' --> 76

3 months ago

Solved

String Logic 7

Examples: 'CAT' --> 84 'DOG' --> 79 'ROSY' --> 89 'MATLAB' --> 84 'TRUST' --> 85 'MOSTLY' --> 89

3 months ago

Solved

String Logic 6

Examples: 'CAT' --> 216 'DOG' --> 218 'ROSY' --> 333 'MATLAB' --> 433 'TRUST' --> 418 'MOSTLY' --> 488

3 months ago

Solved

String Logic 5

Example: 'CAT' --> 'TAC' 'DOG' --> 'GOD' 'MATLAB' --> 'BALTAM' 'ROSY' --> 'YSOR' 'TRUST' --> 'TSURT' 'MOSTLY' --> 'YLTS...

3 months ago