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...
約5年 前
解決済み
Symmetric matrix
You must create a n-by-n *symmetric* matrix such that A(row,col) = row/col for col >= row.
Example if n =3 :
output is :
...
約5年 前
解決済み
Make a Star Pyramid
Create a star pyramid. First line will have 1 star, second will have two stars and so on... a basic program which is easily done...
Special matrix
Make a square matrix with this shape. For n=4
M =
1 1 0 0
1 0 1 0
0 1 0 ...
約5年 前
解決済み
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;
...
Make roundn function
Make roundn function using round.
x=0.55555
y=function(x,1)
y=1
y=function(x,2)
y=0.6
y=function(x,3)
...
約5年 前
解決済み
Rounding off numbers to n decimals
Inspired by a mistake in one of the problems I created, I created this problem where you have to round off a floating point numb...
約5年 前
解決済み
Matlab Basics - Rounding III
Write a script to round a large number to the nearest 10,000
e.g. x = 12,358,466,243 --> y = 12,358,470,000
約5年 前
解決済み
Matlab Basics - Rounding II
Write a script to round a variable x to 3 decimal places:
e.g. x = 2.3456 --> y = 2.346
約5年 前
解決済み
Check that number is whole number
Check that number is whole number
Say x=15, then answer is 1.
x=15.2 , then answer is 0. <http://en.wikipedia.org/wiki/Whole...
約5年 前
解決済み
MATLAB Basic: rounding IV
Do rounding towards plus infinity.
Example: -8.8, answer -8
+8.1 answer 9
+8.50 answer 9