PL/SQL Program to Print Patterns
PL/SQL Program to Print Patterns Here you will know PL/SQL program to print patterns of star, numbers and alphabets by using for and while loops. Pattern 1
1 2 3 4 5 6 7 8 9 10 11 12 13 | DECLARE rows NUMBER := 6; -- to print number of rows i NUMBER; j NUMBER; BEGIN FOR i IN 1..rows LOOP FOR j IN 1..i LOOP DBMS_OUTPUT.PUT('*'); -- Print asterisk END LOOP; DBMS_OUTPUT.PUT_LINE(''); -- Move to the next line END LOOP; END; / |
[…]