Question: Write a program (in java) that takes two binary strings and returns three binary strings. These three strings represent the following binary operations between the

Write a program (in java) that takes two binary strings and returns three binary strings. These three strings represent the following binary operations between the input strings: AND, OR, XOR (make sure it works for strings of different length)

Here are two examples:

Input:

1001

1101

Output:

AND: 1001

OR: 1101

XOR: 0100

Input:

101101

1001

Output:

AND: 1001

OR: 101101

XOR: 100100

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!