• 2022-06-19
    下面两个程序分别用显式赋值语句和隐式赋值语句实现全加器,其中哪一个利用了显式赋值语句?
    A: module fulladder(SUM,C_OUT,A,B,C_IN);input A,B,C_IN;output SUM,C_OUT;assign SUM=(A^B)^C_IN;assign C_OUT=(A&B)| (A^B)&C_IN;endmodule
    B: module fulladder(SUM,C_OUT,A,B,C_IN);input A,B,C_IN;output SUM,C_OUT;wire SUM=(A^B)^C_IN;wire C_OUT=(A&B)| (A^B)&C_IN;endmodule