"know i have to use a for or while loop..."
while/for loop
1 次查看(过去 30 天)
显示 更早的评论
So I have a vector V of which i found its length and i hv used fprintf to print the statement. Now how do i create a new vector from that doubles the elements that are positive and divisible by 3 or 5, raises to the power of 3 the elements that are negative but greater than -5 and excludes all other elements. I know i have to use a for or while loop for this but how would i do so?
0 个评论
回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Loops and Conditional Statements 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!