Prev Problem
Next Problem

12. Vector Bitwise Operators

Back To All Submissions
Previous Submission
Next Submission

Solving Approach

How do you plan to solve it?

 

 

Code

/*Write your code here*/
module bitwise_ops_demo(input [3:0] A, B,output [3:0] AND_OUT,OR_OUT,XOR_OUT,XNOR_OUT);
assign AND_OUT = A&B , OR_OUT = A|B , XOR_OUT = A[3:0] ^ B[3:0]  , XNOR_OUT = ~(A[3:0] ^ B[3:0]);
endmodule

 

Was this helpful?
Upvote
Downvote