Summary

Numbers and strings everywhere! Today you learned quite a lot about scalar data. Perl uses the term scalar data to refer to single things, and most particularly numbers and strings. Scalar variables, which start with $, hold scalar data.

With scalar data in hand, you can create Perl statements, perform arithmetic, compare two values, assign values to variables, change the values of variables, and convert between numbers and strings.

Today you also learned a little about pattern matching, including the pattern matching operators =~ and !~, and the pattern operator m//.

The built-in functions you learned about today include these (we'll go into more detail about some of these tomorrow; see the perlfunc man page for more details about these ...

Get Sams Teach Yourself Perl in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.