Sunan Abi Dawud, Book 2, Hadith 22 (Abu Dawud 412)

Abu Hurairah reported the Messenger of Allah (ﷺ) as saying:

If anyone says a rak'ah of the 'Asr prayer before sunset, he has observed (the 'Asr prayer), and if anyone performs a rak'ah of the Fajr prayer, he has observed (the Fajr prayer).