I would use a C compiler, if available and instruct it to output assembly code instead of object or executable code.

failing that, I would break the program down into a set of very basic operations and implement each one, along with the logic that goes with it. do you know PEP/8 assembly language? if not, you'll likely need to learn it first, unless you have access to a C compiler that can generate PEP/8 code.

Eh, since by "pep8" you mean "A code style standard for python", then the right question to ask is:How would i go about converting a simple guessing game i made in C into a Python program?

Styling your Python code according to the guidelines in PEP-8 is secondary to the task at hand.

Anyway, the answer is: you translate what the C program does into Python. This does not necessarily mean line by line conversion, and sometimes it is easier to just write the Python program from scratch then use the C program to help verify the Python program's correctness.

Originally Posted by Bjarne Stroustrup (2000-10-14)

I get maybe two dozen requests for help with some sort of programming or design problem every day. Most have more sense than to send me hundreds of lines of code. If they do, I ask them to find the smallest example that exhibits the problem and send me that. Mostly, they then find the error themselves. "Finding the smallest program that demonstrates the error" is a powerful debugging tool.