anyone can give us some guideline for python
It would be wise of you to explain the problem in a more elaborate manner. That way surely someone would be able to help you.
I am also a python user.
Here are some tips-
Don’t think that python is too slow because even it may be slow codechef gives 5*times the time limit for python.
Use the benefits of python- for example, shorter code, easy syntax and also the help function.