logo CodeStepByStep logo


Language/Type: Python binary numbers % loops
Related Links:

Write a function named to_binary that accepts an integer as a parameter and returns a string of that number's representation in binary. For example, the call of to_binary(42) should return "101010".

Function: Write a Python function as described, not a complete program.

You must log in before you can solve this problem.

Log In

Need help?

Stuck on an exercise? Contact your TA or instructor.

If something seems wrong with our site, please

Is there a problem? Contact us.