develooper Front page | perl.perl6.users | Postings from May 2018

Real, Num, Rat question

Thread Next
From:
ToddAndMargo
Date:
May 27, 2018 21:49
Subject:
Real, Num, Rat question
Message ID:
32205ec2-5d8b-ef68-c2c9-84466921868a@zoho.com
Hi All,

What is wrong with this picture?  Is my
type being changed or are "Num" and "Rat" in
a subset of "Real"?

Also, what do I alter to get ^name to say real?

$ p6 'my Real $x= 5e65; say $x.^name'
Num

$ p6 'my Real $x= 5.5; say $x.^name'
Rat


Many thanks,
-T

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About