Приглашаем посетить
Гнедич (gnedich.lit-info.ru)

Hour 9. More Functions and Operators

Previous Table of Contents Next

Hour 9. More Functions and Operators

What You'll Learn in This Hour:

  • How to do simple string searches on scalars

  • How to do character substitutions

  • How to use the print function

  • How to use arrays as stacks and queues

The Perl culture follows the tradition of "There Is More Than One Way To Do It," and in this hour, you will look more closely at that philosophy. You will learn a potpourri of new functions and operators.

For scalar searching and manipulation, you've been using regular expressions until this point. There is more than one way to do the job, so Perl provides a variety of functions for searching and editing scalars. In this hour, some of the other ways will be presented.

Also, you've viewed arrays as linear lists of items to be iterated through with foreach or joined together with join to make scalars. In this hour, you'll learn a whole new way of looking at arrays.

Finally, the plain vanilla print function will be revisited—and spiced up a bit. With a new and improved print function, you too can write nicely formatted reports suitable for presentation to others.

    Previous Table of Contents Next