check path a pip module is installed code example
Example 1: how to find where python is located
>>> import os
>>> import sys
>>> os.path.dirname(sys.executable)
'C:\\Python25'
Example 2: how to check if pip is installed
File"stdin",line 1
pip list
Syntax Error: invalid syntax