题解 | #256选1选择器#
256选1选择器
https://www.nowcoder.com/practice/a0b6ee521e534826b44fbf5e24cd4aa0
`timescale 1ns/1ns module top_module ( input [255:0] in, input [7:0] sel, output out ); reg [7:0] rr; //alway中的必须为reg always@(*) begin rr = sel; end assign out = in[rr]; endmodule //注意是以此类推,这是道对位输出的题