File tree Expand file tree Collapse file tree 1 file changed +21
-3
lines changed Expand file tree Collapse file tree 1 file changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -15,8 +15,8 @@ Synopsis 3: Perl 6 Operators
15
15
16
16
Created: 8 Mar 2004
17
17
18
- Last Modified: 31 Mar 2011
19
- Version: 222
18
+ Last Modified: 11 May 2011
19
+ Version: 223
20
20
21
21
=head1 Overview
22
22
@@ -36,7 +36,7 @@ each level:
36
36
N Autoincrement ++ --
37
37
R Exponentiation **
38
38
L Symbolic unary ! + - ~ ? | || +^ ~^ ?^ ^
39
- L Multiplicative * / % %% +& +< +> ~& ~< ~> ?& div mod
39
+ L Multiplicative * / % %% +& +< +> ~& ~< ~> ?& div mod gcd lcm
40
40
L Additive + - +| +^ ~| ~^ ?| ?^
41
41
L Replication x xx
42
42
X Concatenation ~
@@ -879,6 +879,24 @@ C<< infix:<?&> >>, boolean and
879
879
Converts both arguments to type C<Bool> and then ANDs those, returning the
880
880
resulting C<Bool>.
881
881
882
+ =item *
883
+
884
+ C<< infix:<gcd> >>, greatest common divisor
885
+
886
+ $x gcd $y
887
+
888
+ Converts both arguments to an integral type and then finds the largest integer
889
+ that both arguments are evenly divisible by, and returns that integer.
890
+
891
+ =item *
892
+
893
+ C<< infix:<lcm> >>, least common multiple
894
+
895
+ $x lcm $y
896
+
897
+ Converts both arguments to an integral type and then finds the smallest integer
898
+ that is evenly divisible by both arguments, and returns that integer.
899
+
882
900
=back
883
901
884
902
Any bit shift operator may be turned into a rotate operator with the
You can’t perform that action at this time.
0 commit comments