ELEC40006-P1-CW/min.v

8 lines
139 B
Verilog

module min(sign, a, b, num);
input sign;
input [7:0] a;
input [7:0] b;
output [7:0] num;
assign num = sign ? a[7:0]:b[7:0];
endmodule