Skip to content

Commit 865fdcf

Browse files
committed
put
1 parent fc5555b commit 865fdcf

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

doc/Language/py-nutshell.pod6

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ constructs and idioms.
1313
1414
=head2 Hello, world
1515
16-
Let's start with printing "Hello, world!". C<say> in Perl 6 is the
16+
Let's start with printing "Hello, world!". C<put> in Perl 6 is the
1717
equivalent of C<print> in Python. Like Python 2, parentheses are
1818
optional. A return is added to the end of the line.
1919
@@ -27,7 +27,15 @@ Python 3
2727
2828
Perl 6
2929
30-
say "Hello, world!"
30+
put "Hello, world!"
31+
32+
There is also C<say>, which behaves similarly, but will call
33+
the C<gist> method of its argument.
34+
35+
Perl 6
36+
37+
say "Hello, world!"; # also prints "hello world"
38+
say $hello; # same as: put $hello.gist
3139
3240
=head2 Statement Separators
3341

0 commit comments

Comments
 (0)