Can I use whether or not a function runs as a conditional statement?
정보
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
이전 댓글 표시
I need some commands to execute if a pushbutton is pressed while certain other conditions are true. How can I write in a conditional statement "if y and z are true(conditions) and some function has run, then execute these commands" in coding form? This is in a GUI by the way if that helps.
댓글 수: 0
답변 (1개)
elham kreem
2018년 3월 8일
편집: elham kreem
2018년 3월 8일
0 개 추천
this is a short example ; if the first condition is true :
x= 2 ; y = 3;
if (x+y)>4
disp x , disp y
else x-y
end
********************** now if the first condition is wrong :
if (x+y)> 5
disp x , disp y
else x-y
end
댓글 수: 1
Kristen O'Mara
2018년 3월 8일
이 질문은 마감되었습니다.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!