For Loop
for loop - executes once at the start of the loop and then executes if expression is true
integer i; // declare the index for the FOR LOOP
always @(inp or cnt)
begin
result[7:4] = 0;
result[3:0] = inp;
if (cnt == 1)
begin
for (i = 4; i <= 7; i = i + 1)
begin
result[i] = result[i-4];
end
result[3:0] = 0;
end
ÀÌÀü ½½¶óÀ̵å
´ÙÀ½ ½½¶óÀ̵å
ù ½½¶óÀ̵å·Î À̵¿
±×·¡ÇÈ ¹öÀü º¸±â