**Intra-Assignment Timing Delay** What are the values of a and b at time…
**Intra-Assignment Timing Delay** What are the values of a and b at time t = 5 ? reg [3:0] a, b; initial begin a = 4'd1; b = 4'd2; a <= #10 b; b = 4'd8; end
- a = 1, b = 8
- a = 2, b = 8
- a = 2, b = 2
- a = 1, b = 2
Correct answer
A. a = 1, b = 8
Explanation
In a <= #10 b; , b (value 2) is evaluated at $t = 0$, but the scheduled non-blocking update to a occurs at $t = 10$. The line b = 4'd8; is blocking, executing immediately at $t = 0$. Therefore, at $t = 5$, b is 8 and a retains its original value of 1.