British Prime Minister David Cameron said he would resign as Prime Minister by October after Britons ignored his pleas to stay in the European Union and voted in a referendum to leave.