A university student crawled through the air duct of a building in the middle of the night to break into his lecturer's office and steal a copy of an upcoming exam in a statistics class.

Unfortunately for Harry Lynch II, the 21-year-old biosystems engineering student at the University of Kentucky, his professor, John Cain, had chosen to stay and work very late.

Reaching the third floor office Mr Lynch eased himself down from the ceiling - a drop of some eight feet - and then opened the office door from the inside for Troy Kiphuth, a 21-year-old studying agricultural economics, Jay Blanton, university spokesman said.

Mr Cain, the professor, had stepped out for a late night meal. Upon his return at around 1.30am on Wednesday, he found that something was blocking the door from the inside.

“He yelled out that he was calling the police and then the door swung open and two young men ran down the hallway,” Mr Blanton told the Lexington-Herald Leader.

After his initial escape, Mr Lynch realised that the game was up. Concerned that Mr Cain had already been able to identify him as a student of his class, Mr Lynch returned to the Multidisciplinary Science Building and confessed.