Barack Obama believes Scotland has "a lot to offer the world'' and promised to return after his first visit to the country.
Scots Gov Plans Gay/Bi Pardon
The Scottish Government is to grant an automatic pardon to gay and bisexual men convicted of now-abolished sexual offences.
Justice Secretary Michael Matheson confirmed legislation to grant pardons will be brought in at Holyrood, and he added that as part of this process ministers will give ``serious consideration'' to whether they should make a formal apology.
It comes just days after similar legislation was scuppered at Westminster.
Mr Matheson told MSPs: "There are people with criminal convictions for same-sex sexual activity that is now lawful and we must right this wrong.
"We will introduce an automatic formal pardon for those convicted under these discriminatory laws so they know they are absolved fully.''
Last week, the UK Government announced its plans for thousands of gay and bisexual men convicted of out-of-date offences to be posthumously pardoned.
But a Bill brought forward by SNP MP John Nicolson had called on ministers to go further and grant an automatic pardon for the living as well.
Justice Minister Sam Gyimah spoke for more than 20 minutes at the end of a lengthy debate in the House of Commons to prevent the legislation from being put to a vote.
It has become known as the Turing Bill after Second World War codebreaker Alan Turing, who was given a posthumous royal pardon in 2013 over a conviction in 1952 for gross indecency with a 19-year-old man.
Mr Matheson said he regretted the approach the UK Government had taken on the issue as he said the Scottish Government would bring in legislation for an automatic pardon ``at an early date''.
He said: "It is sadly the case that Scotland has only relatively recently modernised our criminal laws so that they no longer discriminate against same-sex sexual activity.
"It is shocking to consider that consensual sex between men was only decriminalised in Scotland in 1980 and the age of consent for same-sex sexual activity was not equalised for sexual activity between men and women until 2001.
"Such laws clearly have no place in a modern and inclusive Scotland.''
Separately, the Scottish Government has been working with Police Scotland to look at how arrangements could be made so that such convictions are disregarded from centrally held records.
Mr Matheson said: "Information on these convictions is held on Police Scotland records and we have engaged with Police Scotland to seek views on steps that could be taken to right these historic wrongs.
"I have instructed my officials, working in partnership with Police Scotland, to determine the practical steps required to establish a scheme to allow men convicted for actions that are now legal to seek to have those convictions disregarded.
"Where an offence is disregarded, a person will be treated as not having been convicted of that offence and so it would not appear on, for example, disclosure checks.''
Fans attending the Scottish Cup Final have been warned to expect delays before the match as security is increased following the attack in Manchester.
Torrential thundery downpours are set to descend on Britain over the bank holiday weekend, bringing an end to the spell of summery weather.
The family of Manchester bomb victim Eilidh MacLeod have said they are praying that her injured friend makes a full recovery.
Most Viewed Pictures On Heart
Recently Played Tracks
To listen live, choose your preferred station:
Now playing: The best feel good music
Now playing: The best feel good music
Deposit £10 to get a £40 Welcome Bonus - That's £50 to play bingo, slots and more!*
Over 50 tracks to make you feel-good. New album out now...
Find your local four day weather report here.
Make Heart the soundtrack to your day and you could be a winner with great prizes up for grabs throughout the day.
Find out more about some of the companies advertising on Heart Scotland- East.