SHARE
TWEET

Untitled

a guest Feb 4th, 2018 82 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. module arrays ();
  3.  
  4.   reg [7:0] array_msb = 8'b1011_0000;
  5.   reg [0:7] array_lsb = 8'b1010_0000;
  6.  
  7.   initial begin
  8.     $display ("array_msb    = %b", array_msb);
  9.     $display ("array_msb[0] = %b", array_msb[0]);
  10.     $display ("array_lsb    = %b", array_lsb);
  11.     $display ("array_lsb[0] = %b", array_lsb[0]);
  12.     #1 $finish;
  13.   end
  14. endmodule
  15.  
  16. ======
  17. The result is
  18. array_msb    = 10110000
  19. array_msb[0] = 0
  20. array_lsb    = 10100000
  21. array_lsb[0] = 1
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top