Had enough of strings and numbers yet? Want to learn more? No problem. This section has a number of other features to look at concerning scalar data before we forge on ahead to lists.
Operators are all discussed in the perlop man page, whereas functions are discussed in the perlfunc man page. As I mentioned before, you can get to all these pages through the use of the perldoc command or on the Web at http://www.perl.com/pub/doc/manual/html/pod/.
Perl includes quite a few built-in functions for a variety of purposes. Appendix E,“Perl Functions,” contains a summary of those functions, and the perlfunc man page also describes them in further detail. In particular, Perl includes a number of useful functions for numbers and strings, including those summarized in Table 3.4. We'll explore some of these in more detail in forthcoming chapters; others you'll have to explore on your own.
Perl provides the usual set of C-like operators for twiddling bits in integers: ~, <<, >>, &, |, and ^, as well as assignment shortcuts for those operators. See the perlop man page for specifics.
In addition to the relational operators I described in the section on comparisons, Perl also has the <=> and cmp operators. The former is for numbers, and the latter for strings. Both return -1, 0, or 1 depending if the left operator is greater than the right, the operators are equal, or if the right operator is greater than the left, respectively. These operators are most commonly used for creating sort routines, which you'll learn more about on Day 8.
Perl's built-in functions actually fall into two groups: functions that are functions, and operators that take one argument and masquerade as functions. The function-like operators fall in the middle of the precedence hierarchy and behave like operators in this respect (whereas function calls with parentheses always have the highest precedence). See the perlop man page under “Named Unary Operators” for a list of these functions.