module mux31(I0, I1, I2, SEL, Y); input I0; input I1; input I2; input [1:0] SEL; output Y; reg Y; always @(I0 or I1 or I2 or SEL) begin case (SEL) 2 : Y <= I2; 1 : Y <= I1; default : Y <= 1'bx; endcase end endmodule