Please help me fix the count for the nested for-loop
이전 댓글 표시
function [ result ] = Clockregister01( R,count )
clc
for j = 1:count
for i = 1: size(RN,1)-1
% RN(i,1:size(RN,2)) = addHexNumber(RN(i,1:size(RN,2)),RN(i+1,1:size(RN,2)))
RN(i) = addHexNumber(RN(i),RN(i+1))
end
end
result = RN;
end
댓글 수: 2
madhan ravi
2018년 11월 30일
편집: madhan ravi
2018년 11월 30일
count value?
Irwin2020
2018년 11월 30일
채택된 답변
추가 답변 (1개)
Dennis
2018년 12월 5일
Your addHexNumber function actually does not work correctly. I think you need to change
if bothSum > 16
to
if bothSum > 15 % or >=16
카테고리
도움말 센터 및 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!