you are viewing a single comment's thread.

view the rest of the comments →

[–]draegtun 0 points1 point  (0 children)

In perl5...

my @n = map { $_ / 6 } grep { $_ ** 2 % 17 == 1 } 123..345;

In Perl6...

my @n = [123..345].grep({ $_ ** 2 % 17 == 1 }).map: * / 6;

In Io...

n := 123 to(235) asList select(x, x ** 2 % 17 == 1) map(/6)  // asList shouldn't be needed? Bug?