Adding random numbers together
显示 更早的评论
So I'm using this code
% Create a vector of 53 random #s and analyze them.
r = rand([53,1])
% The sum of all the random numbers
sum=sum(([53,1]))
disp(result)
But it doesn't seem to be working.
I'm new to ML
How do I find the sum (and product) of the random numbers?
1 个评论
Jan
2013-1-31
Overwriting the function "sum" by a variable called "sum" also will lead to strange effects.
采纳的回答
更多回答(3 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!