Finally a bright idea flashed across his brain.
The man at last had a great idea.