% Ç while åßíáé ãåíéêüôåñç áðü ôç for
% Ïðüôå Ýíáò åðáíáëçðôéêüò âñü÷ïò for ìðïñåß íá ìåôáôñáðåß óå while

clc;
clear all;

for i=1:5
    disp(i);
end

disp('-----------');

i=1;
while i<=5
    disp(i);
    i=i+1;
end

