write a code to Add two numbers using bitwise operators in java

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mahi543
    New Member
    • Aug 2007
    • 5

    #1

    write a code to Add two numbers using bitwise operators in java

    can we write a program in java using bitwise operators to add two numbers
  • JosAH
    Recognized Expert MVP
    • Mar 2007
    • 11453

    #2
    Originally posted by mahi543
    can we write a program in java using bitwise operators to add two numbers
    Yes we can; can you? Have you tried?

    kind regards,

    Jos

    Comment

    • mahi543
      New Member
      • Aug 2007
      • 5

      #3
      Originally posted by JosAH
      Yes we can; can you? Have you tried?

      kind regards,

      Jos
      yes i tried i have got logic with using xor operator we can add two numbers by changing them into binary digits but how can we write the code for that

      Comment

      Working...