I downloaded the file "Python-3.5.0.tgz" from Python.org. Then I typed the following:
$ tar xvzf Python-3.5.0.tgz
sudo make install
You are most likely not compiling Python with SSL/TLS support. You are probably missing the SSL development libraries. Install the following dependencies, and then re-configure and re-compile Python 3.5.
apt-get install -y make build-essential libssl-dev zlib1g-dev libbz2-dev libsqlite3-dev
yum install zlib-devel bzip2-devel sqlite sqlite-devel openssl-devel