CMIT100 Chapter 14 - Programming
Learning Objectives Describe the differences between high level language and low level programming. Discuss the evolution of programming languages with an examination of innovations in programming. Introduce the types of programming language instructions. Introduce through examples programming in both the Bash shell and DOS languages.
Does a System Administrator Program? System Administrators are generally not developers But… May need to support/maintain/install in-house applications Will likely create shell scripts or PowerShell scripts to automate administrative tasks
Low-level vs. High-level Languages Machine language Assembly language High-level C C++ C# Visual Basic And many more…
Machine Language Binary Native Language of the computer Differs between processor types Extremely difficult for humans
Language Translators Translates from a higher-level language to the machine language of a given processor Three types: Assemblers Compilers Interpreters
Compiled Languages vs. Interpreted Languages What’s the difference? Examples of Compiled languages: C C++ Examples of Interpreted languages: Shell scripts Windows Batch files Perl
Assembly Language Higher level than machine language but still considered low level Easier for humans than machine language but still challenging Allows for extremely efficient code
High Level Languages Human-like syntax Examples: FORTRAN (legacy) COBOL (Legacy) C C++ C# Perl Java
Object-Oriented vs. Structured Languages Early languages were structured Examples: C, Fortran Modern Languages are Object-Oriented Examples: C++, Java Visual Programming Integrated Development Environment (IDE) Example: Microsoft Visual Studio
Types of Programming Statements Input/Output Statements Examples: OPEN, PRINT, READ Selection Statements Conditions (true/false) If-then-else Iteration Statements
Subroutines and Subroutine Calls Allows for modular programming Also known as functions
Scripting Languages Interpreted Commonly used by System Administrators to automate tasks Exist as executable text files Integrated into all modern operating systems Examples: Linux Shell PowerShell Perl
LAB “Hello World” Shell Script
Creative Commons Statement