The Program Development Cycle


The program development life cycle (PDLC) is the process containing the seven phases of program development:

Software Development Cycle

Types of Programming Errors


Programming errors come in two main forms:

  • Syntax Errors - These are errors in the typed out code that will not allow your program to run. For example, typographical errors are syntax errors.

  • Logic Errors - These are errors in the logic of the program. In other words, the program will run, but yield unexpected results. These are MUCH more difficult to fix than syntax errors.

Pseudocode


Pseudocode is one of the main tools programmers use while planning the logic and flow of a program. Pseudocode is not quite code and it's not quite English, it's a mixture of both that allows you to quickly write out the solution to your program without being slowed down by worrying about using proper syntax. You can think of pseudocode as "notes" for planning out a program.

Examples:

Number Doubling Program

start

 input myNumer
 set myAnswer = myNumber * 2
 output myAnswer

stop





Old Enough to Drive Program

start

 input age

 if age < 16:
  print "You cannot drive."
 else:
  print "You can drive."

stop


Add Numbers Program

start

 total = 0
 num = input("Enter a number or 0 to quit: ")

 while num != 0:
  total = total + num
  num = input("Enter a number or 0 to quit: ")

 output total

stop


Flowcharts


Flowcharts are another main tool programmers use while planning the logic and flow of a program. Flowcharts show the same solution as pseudocode, except in a more visual form. Below are a few of the basic shapes used to create flowcharts.

Flowchart Symbols



Examples:


Number Doubling Program

Number Doubling Program

Add Numbers Program

Number Doubling Program

Old Enough to Drive Program

Number Doubling Program


The 3 Fundamental Programming Structures


Below are the three fundamental programming structures of computer science. Theoretically, you can create any program that has ever been written using only these three structures. As you place these structures into your flowchart, you can both stack them (one structure on top of another) or nest them (one structure inside of another). This is referred to as stacking and nesting.

Flowchart Symbols