Course Solutions Uncategorized (Solved) : Create Python Function Called Binaryadd Takes Two Strings Binary Expansions Aand B Returns Q30913620 . . . .

(Solved) : Create Python Function Called Binaryadd Takes Two Strings Binary Expansions Aand B Returns Q30913620 . . . .

 

Create a Python function called binaryAdd( ) that takes in twostrings of binary expansions, aand b, and returns the sum of thebinary expansions as a string. For example,

>> binaryAdd(“10101”, “101011”) >> ‘1000000’

What I have so far …

def binaryAdd(a, u):
“””
INPUT: a, u strings of 0’s and 1’s which are the binary reps of aand u
OUTPUT: string representation of the binary sum
“””
c = 0
s = []
k = 0
if (len(a) > len(u)):
k = len(a)
for i in range (len(u), len(a)):
u =

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

(Solved) : 13 Operator Correct Relational Operator Inequality Ml B C D 14 Result Relational Expressio Q32707452 . . . .(Solved) : 13 Operator Correct Relational Operator Inequality Ml B C D 14 Result Relational Expressio Q32707452 . . . .

<p>13. Which operator is a correct relational operator forinequality in ML?<br/>(A) /=<br/>(B) NOT=<br/>(C) !=<br/>(D) <><br/></p><p>14. What is the result of the relational expression inJavascript below:<br/>"7" === 7<br/>(A) true<br/>(B) false<br/>(C) null<br/>(D)