Uganda’s longtime president will continue his rule over a population where three-quarters are below 30 and have never known anyone else in charge.