Raku One-Liners
Short, powerful Raku programs — command-line one-liners for files, numbers, strings, and dates, a tour of the language’s most expressive syntax, a round of Raku golf, and a look behind floating-point arithmetic.
Preface
Command-Line Options
Working with Files
Working with Numbers
- Grepping multiples of 3 and 5
- Generating random integers
- Working with big numbers
- Testing palindromic numbers
- Adding up even Fibonacci numbers
- Playing with Fibonacci numbers
- Distance between two points
- Playing with prime numbers
- Using map and Seq to compute the value of π
- Computing totals
- Sum of the numbers equal to the sum of factorials of digits
- 42 via the cubes
Working with Strings
Working with Dates
- What’s the date today?
- How many days in the century match the condition?
- Another solution of the same prob- lem
Raku Syntax
Raku Golf
Appendix on Compiler Internals
Afterword
Course navigation
← The Raku Course | Preface →