convert php in to python

Chris Angelico rosuav at gmail.com
Mon Nov 30 03:48:38 EST 2015


On Fri, Nov 27, 2015 at 11:52 PM, RENISH RUDANI <delphicr at gmail.com> wrote:
> Please help me to convert this code in python.
>
>
> *Thanks & Regards,*
>
> *Renish Rudani*
>
> *Action Speaks Louder than Words*

Sure.

#!/usr/bin/python3
"""Emit no output"""

You didn't provide any PHP code, so the equivalent Python code is
actually an empty file. I put in a docstring and a shebang so you'd be
able to find what I wrote.

It's possible you included an attachment, but attachments don't always
survive as far as the newsgroup/mailing list.

Translating code from one language to another usually requires
comprehension of what the code's trying to accomplish. You might have
to dig into the code a bit and get to know it, and then recreate it in
Python. It's not a simple question, unless the code itself is
trivially simple.

Good luck! At least you're migrating to a better language.

ChrisA



More information about the Python-list mailing list