All programming languages give developers the ability to create their own subroutines, blocks of code that allow generality and reuse. This chapter examines the principles of subroutines in Perl.
All high-level languages offer ways in which a large program may be partitioned into manageable pieces. This divide-and-conquer strategy leads to easier debugging, maintenance, and readability. Different programming languages use different names for these partitions of reusable code. Some of these names are methods, subprograms, procedures, functions, and subroutines. Perl tends to use the latter two names more than the other names.
18.222.196.175