Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Q&A

Post History

60%
+1 −0
Q&A Is it possible to design an n-bit full adder using SystemVerilog?

I am trying to design a full adder in SystemVerilog. I searched on Wikipedia and I found this https://en.wikibooks.org/w/index.php?title=Microprocessor_Design/Add_and_Subtract_Blocks module full_...

1 answer  ·  posted 3y ago by System‭  ·  last activity 3y ago by System‭

#6: Post edited by (deleted user) · 2021-02-23T12:59:31Z (about 3 years ago)
  • How do I design an n-bit full adder using SystemVerilog?
  • Is it possible to design an n-bit full adder using SystemVerilog?
#5: Post edited by (deleted user) · 2021-02-23T12:59:00Z (about 3 years ago)
  • How do I design n-bit full adder using SystemVerilog?
  • How do I design an n-bit full adder using SystemVerilog?
#4: Post edited by (deleted user) · 2021-02-23T12:58:46Z (about 3 years ago)
#3: Post edited by (deleted user) · 2021-02-23T12:55:27Z (about 3 years ago)
#2: Post edited by (deleted user) · 2021-02-23T12:52:49Z (about 3 years ago)
  • How to design n-bit full adder in SystemVerilog?
  • How do I design n-bit full adder using SystemVerilog?
#1: Initial revision by (deleted user) · 2021-02-23T12:45:59Z (about 3 years ago)
How to design n-bit full adder in SystemVerilog?
I am trying to design a full adder in SystemVerilog. 

I searched on Wikipedia and I found this https://en.wikibooks.org/w/index.php?title=Microprocessor_Design/Add_and_Subtract_Blocks

```
module full_adder(a, b, cin, cout, s);
   input a, b, cin;
   output cout, s;
   wire temp;
   temp = a ^ b;
   s = temp ^ cin;
   cout = (cin & temp) | (a & b);
endmodule
```

But this code seems quite lengthy, and works for only the 1-bit case. Is there code which is shorter and can work for the n-bit case?