Is there a command in the interactive shell that copies the last expression to the clipboard?
I know there's the _
command, which repeats the last expression's evaluation, e.g.
>>> " ".join(['a', 'b', 'c'])
'a b c'
>>> _
'a b c'
But what I'm looking for is a command that copies " ".join(['a', 'b', 'c'])
to the clipboard. Is there such a thing?