Index in position 1 exceeds array bounds (must not exceed 1)
조회 수: 2 (최근 30일)
이전 댓글 표시
This is my script :
kwh=input('How much KWH this month :');
ckwh=6.6*kwh/100;
fprintf('Your charge for %5d will be %.2d',kwh,ckwh)
Matlab return this : Index in position 1 exceeds array bounds (must not exceed 1).
Help me please !!!
댓글 수: 0
답변 (2개)
madhan ravi
2019년 9월 23일
편집: madhan ravi
2019년 9월 23일
clear all % you're probably shadowing the inbuilt function input()\fprintf()
%or
clear input fprintf
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Matrix Indexing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!