How to check for condition without using a loop or if statement.
이전 댓글 표시
The problem set up is this: Given vector A, and the average value of the elements in vector A, track the number of times an element in vector A is greater than the average value of elements in A.
The issue is that I'm not allowed to use a loop or and if statement.
답변 (1개)
Image Analyst
2018년 10월 19일
0 개 추천
Since it's homework, we can't give you the answer outright. So read this link: http://www.mathworks.com/matlabcentral/answers/8626-how-do-i-get-help-on-homework-questions-on-matlab-answers
Hint: use mean(), the greater than symbol, and sum().
카테고리
도움말 센터 및 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!