Create a cell array out of a struct
Create a cell array out of a (single) struct with the fieldname in the first column and the value in the second column:
in:
...
3年弱 前
解決済み
Count number of words in string
Count number of words in string
Examples
'hi', answer is 1
'hi hi', answer is 2
'I enjoy cody', answer is 3
3年弱 前
解決済み
Determine the mean of matrix
Determine the mean of matrix without using mean function
Hint: use simple algorithm
3年弱 前
解決済み
Deleting an element in a matrix
For vector Grades=[98 56 78 34 100 88 87], delete the number 78 to get the following matrix
Grades=[98 56 34 100 88 87]
**re...
3年弱 前
解決済み
Return 'on' or 'off'
When the input is true, return 'on', otherwise, return 'off'.
Return unique values without sorting
If the input vector A is [42 1 1],
the output value B must be the unique values [42 1]
The *values of B are in the s...
Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so:
x = [1 2 3 4]
Commas are optional, s...
3年弱 前
解決済み
Find max
Find the maximum value of a given vector or matrix.