George Glazier, 18, was caught on the A272 in Petersfield as he drove four friends to get fast food after a party, at about 2am on October 27.
The college pupil of Conford Road, Liphook, admitted driving above the alcohol limit as he appeared at Portsmouth Magistrates Court yesterday.
Prosecuting, Graham Heath said Glazier, who studies in Godalming and turned 18 in September, was stopped by police as his ‘erratic’ driving saw him swerving across the centre of the road after a visit to the 24-hour McDonald's in Winchester Road, Petersfield.
A breath test found he had 40 microgrammes of alcohol in 100ml of breath. The legal limit is 35 microgrammes.
Natalie Dennington, mitigating, said: ‘He thought he was okay to drive to McDonald's to get some food because his friends were hungry – he was very surprised he was over the limit.
‘He regrets what he has done and he is very remorseful for his actions.’
Glazier, whose parents watched on as he was sentenced, was also asked to pay £197 – including costs and an £80 fine.
Bench chairwoman Jane Short said she hoped he ‘learned a very hard lesson’.
‘It’s never safe to drive when you have been drinking,’ she told him.
‘Just be thankful on this occasion no one has been seriously hurt or killed. That is a very real possibility.’