






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!







1 2 3 4 5 6 7 8 9 10 11 12 1 2 3 4 5 6 7 8 9 10 11 12
a_plus_b(1,2) d=a_plus_b(3,4)
total= for ( i=-1:-100 ) total=total+i end % 1부터 99 까지의 홀수의 합 total= for (i=1:2:99) total=total+i end
total= for ( i=1:100 ) total=total+i end total=-total
i= while i< i=i+ end
i= total= while i< i=i+ total=total+i end
i= total= while i< i=i+ total=total-i end % 1 부터 99 까지 홀수의 합 i= total= while i< i=i+ total=total+i end
a= if a== disp(‘a는 1 입니다.’) elseif a== disp(‘a는 0 입니다.’) else disp(‘a는 1 도아니고 0 도 아닙니다.’) end a=[1 2 3 1 0 1] for i=1:1:length(a) if a(i)== disp(‘a는 1 입니다.’) elseif a(i)== disp(‘a는 0 입니다.’) else disp(‘a는 1 도 아니고 0 도 아닙니다.’) end end
score = input(‘너의 성적은…?’) if score>= disp(‘A’) elseif score>= disp(‘B’) elseif score>= disp(‘C’) else disp(‘D’) end