Active Outline
General Information
- Course ID (CB01A and CB01B)
- CISD033A
- Course Title (CB02)
- Programming in PERL
- Course Credit Status
- Credit - Degree Applicable
- Effective Term
- Fall 2023
- Course Description
- A complete coverage of the core Perl language. Topics covered will include: basic loops and control structures, the elemental data types and operators, subroutines and variable scooping, regular expressions and text parsing, manipulation of files, advanced list processing with grep and map, references, built-in functions and core modules, and advanced input/output including random-access files and formatting.
- Faculty Requirements
- Course Family
- Not Applicable
Course Justification
Perl is an important language in several important programming activities, including system administration, web servers, management of interfaces between programs and various string management applications. It is CSU and UC transferable and belongs on the Programming in Perl Certificate.
Foothill Equivalency
- Does the course have a Foothill equivalent?
- No
- Foothill Course ID
Formerly Statement
Course Development Options
- Basic Skill Status (CB08)
- Course is not a basic skills course.
- Grade Options
- Letter Grade
- Pass/No Pass
- Repeat Limit
- 0
Transferability & Gen. Ed. Options
- Transferability
- Transferable to both UC and CSU
°®¶¹´«Ã½ GE | Area(s) | Status | Details |
---|---|---|---|
2G4M | DA and 4-yr GE Math Ag | Approved |
Units and Hours
Summary
- Minimum Credit Units
- 4.5
- Maximum Credit Units
- 4.5
Weekly Student Hours
Type | In Class | Out of Class |
---|---|---|
Lecture Hours | 4.0 | 8.0 |
Laboratory Hours | 1.5 | 0.0 |
Course Student Hours
- Course Duration (Weeks)
- 12.0
- Hours per unit divisor
- 36.0
Course In-Class (Contact) Hours
- Lecture
- 48.0
- Laboratory
- 18.0
- Total
- 66.0
Course Out-of-Class Hours
- Lecture
- 96.0
- Laboratory
- 0.0
- NA
- 0.0
- Total
- 96.0
Prerequisite(s)
Corequisite(s)
Advisory(ies)
ESL D272. and ESL D273., or ESL D472. and ESL D473., or eligibility for EWRT D001A or EWRT D01AH or ESL D005.
CIS D022B or CIS D026A
Limitation(s) on Enrollment
Entrance Skill(s)
General Course Statement(s)
Methods of Instruction
Discussion of assigned reading
Discussion and problem solving performed in class
Lecture and visual aids
Quiz and examination review performed in class
Homework and extended projects
Collaborative learning and small group exercises
Collaborative projects
Laboratory experience which involve students in formal exercises of data collection and analysis
Laboratory discussion sessions and quizzes that evaluate the preceding weeks laboratory exercises
Assignments
- Reading: Required reading from text and handouts
- Writing: Six to nine scripts of increasing length covering the Lab Topics specified in X. (half completed in the computer lab, half completed for homework)
Methods of Evaluation
- A minimum of one one-hour midterm exam with at least two multi-line Perl scripts which must be correct and complete code that conforms to the Perl style guide. Also correct completion of laboratory assignments and homework assignments that conforms to the Perl style guide.
- A comprehensive final exam including the writing of scripts involving topics of course which must be correct and complete code that conforms to the Perl style guide.
Essential Student Materials/Essential College Facilities
Essential Student Materials:Â
- None.
- Access to a computer with a Perl recent version Interpreter
Examples of Primary Texts and References
Author | Title | Publisher | Date/Edition | ISBN |
---|---|---|---|---|
Wall, Larry, Tom Christiansen, bryan d foy, and Jon Orwant. "Programming Perl: Unmatched power for text processing and scripting, edition 4", Sebastopol, CA: O'Reilly Media, 2012. |
Examples of Supporting Texts and References
Author | Title | Publisher |
---|---|---|
Swartz, Randal L., brian d foy, and Tom Phoenix, "Lerning Perl: Making Easy Things Easy and Hard Things Possible, Edition 7", 2016 | ||
Beginning Perl (first edition) by Simon Cozens free on-line at: http://www.perl.org/books/beginning-perl | ||
http://perldoc.perl.org |
Learning Outcomes and Objectives
Course Objectives
- Create programs using regular expressions and scalar operators to parse, analyze and error-check files, user input and other data.
- Create programs which create and use lists and move data between lists and files
- Create programs which create and use hashes to store data, prevent duplicate data, and count frequencies of occurrence of events.
- Create programs which generate files and/or manipulate files and their attributes
- Create programs which search for or alter substrings within strings
- Create programs which selectively access portions of files rather than entire
- Create programs which use advanced list functions to filter out elements of a list or use formulae to change the contents of a list
- Create programs which use references to pass lists or hashes to functions or to build multidimensional data structures
- Create programs that access the operating system with command substitution and pipes
- Review the items needed as background for this course.
CSLOs
- Design, code, document, analyze, debug, and test introductory level Perl programs that include Perl modules and use operating system features.
Outline
- Create programs using regular expressions and scalar operators to parse, analyze and error-check files, user input and other data.
- Testing user input from a terminal against a regular expression
- Regular expressions and substitution
- Saving and using fields captured by a regular expression
- The arithmetic operators
- The string casing functions
- The concatentation and replication operators
- The matching operator
- The translation operator
- Boolean operations and the if statement
- Using inverted if statements
- Create programs which create and use lists and move data between lists and files
- Constructing lists
- Removing elements from lists with pop and shift
- Adding elements to a list with push, unshift, and splice
- Creating lists with split, match global, and match tagged field
- The concept of list in a scalar context
- Command line arguments and the @ARGV built-in list including use of (less than symbol)ARGV(greater than symbol) and $ARGV
- Building a list from file data
- Collapsing a list into a scalar with join function
- Iterating over a list with foreach
- Iterating over a list with the for loop
- Iterating over a list with the while loop
- Iterating over a list with an until loop
- Iterating with a do while loop
- Iterating with a do until loop
- Create programs which create and use hashes to store data, prevent duplicate data, and count frequencies of occurrence of events.
- Constructing hashes
- The basic hash manipulation functions keys, values, delete, exists,and each index
- Using hashes for applications that must access data by a string key rather than an array index
- Using hashes to remove duplicate data from a list or file
- Create programs which generate files and/or manipulate files and their attributes
- Opening files
- Reading and writing files
- Gathering data from chaotically formatted files
- Gathering data from files with regular field delimiters
- Writing formatted files with the print function
- Getting file attibutes with the filetest operators
- Changing file access permissions with the chmod function
- Renaming files with the rename function
- Removing files with the unlink function
- Copying files with the copy function
- Create programs which search for or alter substrings within strings
- The index function
- The rindex function
- The rvalue form of the substr function
- The lvalue form of the substr function
- Create programs which selectively access portions of files rather than entire
- The built-in $.Variable
- Using $. To access files by line number
- Accessing a range of line numbers with..
- Accessing files via pattern matching with the.. and .. operators
- Random file access with seek and tell
- Create programs which use advanced list functions to filter out elements of a list or use formulae to change the contents of a list
- Selecting and filtering lists with the grep function
- Transforming list elements with the map function
- Create programs which use references to pass lists or hashes to functions or to build multidimensional data structures
- Passing lists and hashes to subroutines by reference
- Building multidimensional data structures with references
- Using grep and map with reference-based data structures
- Create programs that access the operating system with command substitution and pipes
- Command substitution in a scalar context
- Command substitution in a list context
- Writing to pipes
- Reading from pipes
- Review the items needed as background for this course.
- Design, code, debug, and document programs using appropriate modularity and coherent functions. Pass arguments be value and by address.
- Design, code, and test programs using structures with arrays, functions, and pointers and also using pointers with arrays, functions, and structures.
- Design, code, and test programs using the string Input/Output functions and string manipulation functions. Create functions to manipulate strings.
- Use UNIX/Linux shell commands, including pipe and tee.
- use the UNIX/Linux directory structure.
- Use regular expressions.
Lab Topics
- User input evaluation and arithmetic expression evaluation
- Creation pf lists from file data and list slicing
- Creation of hashes from file data and use in duplicate prevention and frequency counting
- File attribute testing
- Use of grep and map power tools for loop-less list processing
- Use of references to create multidimensional data structures and to pass lists and hashes to subs by reference