pip3
and conda
are utilities separate to the Python programming language. pip3
and conda
make it easier for users to install python packages to their machine/virtual environment which is why you get SyntaxError: invalid syntax
because what you've written is not valid Python.
If you want to use pip3
or conda
these commands should be used at into a terminal. These tools search online for modules you want to install, download them and install them into the appropriate location (for your user or into your virtual enviroment). If you try to install something that can't be found online in the pypi you'll get an error.
You've tried to install the module csv
using pip3 install csv
. The csv
module is part of Python's standard library so pip3
will not find this package on pypi. Being part of the standard library means that every installation of Python has this library. To use the csv
module you can do import csv
in your notebook/.py
file. The same goes for the module time
.