Even the M-16, which has been in service for 50 years or so, longer than any other U.S. military rifle.
Let us not forget the venerable M-14 which was brought back into service for Afghanistan, and is used as a designated marksman rifle at platoon level.
It seems that the M-4 and the M-16 didn’t have the range needed, and even if the troop could hit a target with the M-16, he couldn’t be sure of a kill at that range.