CS 211: Intro to Scripting

Class Program
Distribution
Specified Elective
Credits 3 Lecture Hours 11 Lab Hours 44

An introductory scripting course. Students will explore the fundamental principles of scripting and learn to write and debug simple scripting language to add functionality to programs. Topics for study include input/output, operations, pipes, shell variables, control structures, file input and output, regular expressions, and navigation within a file system

Prerequisites

Recommend CS 111, Linux experience, or instructor permission

Course Outcomes

Upon successful completion of the course, students should be able to demonstrate the following knowledge or skills:

  1. Set up a Linux environment such as a that in a Virtual Machine, Docker image, Raspberry Pi, or as a native operating system to run scripts written in Python, Bash, or PowerShell.
  2. Navigate a file system using a command line interface.
  3. Write re-usable scripts that will automate repetitive tasks within an operating system.
  4. Compose scripts that will read input from a file or command line arguments and write output to a file.
  5. Write basic scripts that will take input and display output to the screen.
  6. Use regular expressions to filter through files and data.
  7. Define shell variables and use them properly in statements and expressions.
  8. Apply control structures (sequence, decision, and repetition) to correctly control the flow of a script.
  9. Use pipes to capture output from one program and use it in another program.
Institutional Outcomes

IO1       Communication: Students will be able to communicate clearly and effectively within a workplace context

IO2       Quantitative Reasoning: Analyze and solve computational problems using a modern program language

Course Content Outline
  1. Linux environment setup and commands used to navigate file system.
  2. Commands, arguments, and control operators.
  3. Shell variables, shell embedding, file globbing.
  4. Pipes, input, and output redirection.
  5. Filters and basic Unix tools.
  6. Regular expressions.
  7. Sourcing a script, she-bang, variables, and numerical expressions.
  8. Scripting loops and conditional statements.
  9. Scripting parameters and scripting functions.
Department Guidelines

PO6      Deploy and manage server hardware and software to support organizational operations and goals