module ADDF (COUT,SUM,A,B,CIN);

  output  COUT;
  output  SUM;
  input   A;
  input   B;
  input   CIN;

  wire net1,net2,net3;
  wire SUM,COUT,A,B,CIN;

  xor x0 (SUM,A,B,CIN);
  or  o1 (net1,A,B);
  and a1 (net2,net1,CIN);
  and a2 (net3,A,B);
  or  o2 (COUT,net2,net3);

endmodule
