Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

Using a vector in an If statement for comet plot

조회 수: 1 (최근 30일)
ctin
ctin 2018년 3월 19일
마감: MATLAB Answer Bot 2021년 8월 20일
I have a matrix that represents a total score for each round. I want to form a loop that goes through the matrix with a nested If statement for if the first element is odd, then playerBscore gets +1 and if first element is even, then playerAscore gets +1 and so on throughout the matrix so I can plot the function for each round on comet. I'm not sure what to set the initial playerBscore and playerAscore as either.

답변 (1개)

KSSV
KSSV 2018년 3월 19일
편집: KSSV 2018년 3월 19일
Read about mod,,this will help you to know whether the given number is even or odd.

이 질문은 마감되었습니다.

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by