A+B

Short version with very little "line noise":

get.words.sum.say;

Reduction operator [+], and say as a function:

say [+] get.words;

Long version:

my ($a, $b) = $*IN.get.split(" ");
say $a + $b;