clear; clc;

disp("Case A");
for j = 1 : 5
    for i = 1 : j
        fprintf("*");
    end
    fprintf("\n");
end

disp("Case B");
for j = 5 : -1 : 1
    for i = 1 : j
        fprintf("*");
    end
    fprintf("\n");
end

for j = 1 : 5
    for i = 1 : 6 - j
        fprintf("*");
    end
    fprintf("\n");
end
