How do I generate a string during a loop
조회 수: 2 (최근 30일)
이전 댓글 표시
I'm looking to generate a string, such as 'grape', when a certain value, say, 0.5, is encountered during a loop. How do I do this?
댓글 수: 3
Eric
2017년 11월 2일
if value==0.5
'grape'
end
If you want to actually do something with it, save it in a variable. Not sure what you want to do with the 'grape' string.
답변 (0개)
참고 항목
카테고리
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!