필터 지우기
필터 지우기

How to write if statement?

조회 수: 2 (최근 30일)
Anne Nguyen
Anne Nguyen 2019년 10월 6일
댓글: Walter Roberson 2019년 10월 6일
How do I write an if statement saying if either input is a matrix, my program should throw a unique error message? (I cannot use isvector function, I think I am supposed to use length() or size() functions if that is possible). Thank you!
  댓글 수: 1
Walter Roberson
Walter Roberson 2019년 10월 6일
How do you define matrix for this purpose? Which of these are a matrix ?
zeros(0,0)
zeros(0,1)
zeros(0,10)
zeros(1,0)
zeros(1,1)
zeros(1,10)
zeros(10,10)
zeros(0,0,0)
zeros(0,10,10)
zeros(10,0,10)
zeros(10,10,0)
zeros(1,10,10)
zeros(10,1,10)
zeros(10,10,1)
zeros(10,10,10)

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

태그

제품

Community Treasure Hunt

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

Start Hunting!

Translated by