Word Counting and Indexing
You are given a list of strings, each being a list of words divided by spaces. Break the strings into words, then return a maste...
2年以上 前
解決済み
Counting Sequence
Given a vector x, find the "counting sequence" y.
A counting sequence is formed by "counting" the entries in a given sequence...
2年以上 前
解決済み
Is the Point in a Triangle?
Check whether a point or multiple points is/are in a triangle with three corners
Points = [x, y];
Triangle = [x1, y1; x...
Matlab Basics - Rounding II
Write a script to round a variable x to 3 decimal places:
e.g. x = 2.3456 --> y = 2.346
2年以上 前
解決済み
Remove element(s) from cell array
You can easily remove an element (or a column in any dimension) from a normal matrix, but assigning that value (or range) empty....
2年以上 前
解決済み
Pernicious Anniversary Problem
Since Cody is 5 years old, it's pernicious. A <http://rosettacode.org/wiki/Pernicious_numbers Pernicious number> is an integer w...
2年以上 前
解決済み
"mirror" matrix
Create n x 2n "mirror" matrix of this type:
Examples
For n = 2
m = [ 1 2 2 1
1 2 2 1 ]
For n = 3
m = ...
2年以上 前
解決済み
Sum of series
a(n) = n^2 - (n-1)^2
find the summation of the series upto n i.e.
a(1)+a(2)+...+a(n)
2年以上 前
解決済み
Unique - Very Very Large Numbers
Given a vector column, with some very large numbers, create the ascending sort and unique vector.
*Input:* A (column vector)...
Hemisphere Volume on Top of a Cylinder
This MATLAB function has to calculate the volume of a hemisphere placed on top of a cylinder, given valid inputs. It takes the r...
2年以上 前
解決済み
findPositiveEvenNumbers
Write a MATLAB function findPositiveEvenNumbers that takes an array of integers as input and returns a new array containing only...