Performance of electron reconstruction and selection with the CMS detector in proton-proton collisions at √s = 8 TeV