Former U.S. President Barack Obama advised France's presidential hopeful Emmanuel Macron to work hard until the very last minute of the campaign.