Community Profile # F.

Active since 2012

#### Statistics

All
• • • #### Content Feed

View by

Vector and matrix index operations
What do you think about something like this : myvect={'101AA21' '101AA22' '101AA23' '102AA21' '102AA22'}; mymatrix = ma...

circa 7 anni ago | 0

Solved

Determine whether a vector is monotonically increasing
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...

circa 9 anni ago

how to concatnate cells within a column
I think you should try this: % code strcat( sprintf( '%s||', Data2 .REGIMEN{1:end-1} ) , Data2.REGIMEN{end} ) OR % c...

circa 9 anni ago | 0

Solved

Who Has the Most Change?
You have a matrix for which each row is a person and the columns represent the number of quarters, nickels, dimes, and pennies t...

circa 10 anni ago

Solved

Find the numeric mean of the prime numbers in a matrix.
There will always be at least one prime in the matrix. Example: Input in = [ 8 3 5 9 ] Output out is 4...

circa 10 anni ago

Solved

Make a checkerboard matrix
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Example...

circa 10 anni ago

Solved

Which doors are open?
There are n doors in an alley. Initially they are all shut. You have been tasked to go down the alley n times, and open/shut the...

circa 10 anni ago

Solved

Return the 3n+1 sequence for n
A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the number is e...

circa 10 anni ago

Solved

Back and Forth Rows
Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 wind back and forth along the rows as shown in the...

circa 10 anni ago

Solved

Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

circa 10 anni ago

Solved

Pizza!
Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

circa 10 anni ago

Solved

Target sorting
Sort the given list of numbers |a| according to how far away each element is from the target value |t|. The result should return...

circa 10 anni ago

Solved

Remove any row in which a NaN appears
Given the matrix A, return B in which all the rows that have one or more <http://www.mathworks.com/help/techdoc/ref/nan.html NaN...

circa 10 anni ago

Solved

Given a and b, return the sum a+b in c.

circa 10 anni ago

Solved

Find the longest sequence of 1's in a binary sequence.
Given a string such as s = '011110010000000100010111' find the length of the longest string of consecutive 1's. In this examp...

circa 10 anni ago

Solved

Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

circa 10 anni ago

Solved

Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

circa 10 anni ago

Solved

Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

circa 10 anni ago

Solved

Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

circa 10 anni ago

Solved

Finding Perfect Squares
Given a vector of numbers, return true if one of the numbers is a square of one of the other numbers. Otherwise return false. E...

circa 10 anni ago

Solved

Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...

circa 10 anni ago

Solved

Is my wife right?
Regardless of input, output the string 'yes'.

circa 10 anni ago

Solved

Duplicate each element of a vector.
for an n-dimensional vector x, the function should return another vector 2n-dimension which each element is repeated twice. Ex...

circa 10 anni ago

Solved

Assign numerical values to a structure with 1 field
The aim is to assign values to a multidimensional structure *without using for-loop or while-loop* Example with a structure ...

circa 10 anni ago

Solved

Removing rows from a matrix is easy - but what about inserting rows?
Assume A is a 5-by-5 matrix. A([2,4],:) = [] is a quick way to remove rows 2 and 4. Can you find a quick way to insert rows into...

circa 10 anni ago

Solved

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

circa 10 anni ago

Solved

Cody Computer Part 5 - Guess the Name of Cody Computer
Network computers have generally a nickname to be identified. Can you guess the nickname of the Cody Computer? No inpu...

circa 10 anni ago

Solved

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

circa 10 anni ago

Solved

Check if number exists in vector
Return 1 if number _a_ exists in vector _b_ otherwise return 0. a = 3; b = [1,2,4]; Returns 0. a = 3; b = [1,...

circa 10 anni ago

Solved

Most nonzero elements in row
Given the matrix a, return the index r of the row with the most nonzero elements. Assume there will always be exactly one row th...

circa 10 anni ago