|
| Program Testing - Lets the programmer know if the program is working
- Various errors:
- Syntax errors – when instructions do not follow the specified format
- Runtime errors – appear while the program is running; instructions that the computer cannot execute
- Logic error – logical design error; incorrect formulas or calculations
Program Documentation - Programmers insert comments into the code
- Function descriptions are also included and these are also considered as comments
Procedural Programming and Object-Oriented Programming What is procedural programming? - It is a concept/paradigm
- Seen as a way of solving problems using a sequence of steps
- A programming language that supports the procedural paradigm is called a procedural language (machine language, assembly language, C and other 3rd generation languages)
What is an Algorithm? - An algorithm is a set of steps for carrying out a task that can be written down and implemented
- Expressed as instructions
- To design an algorithm; take note of the steps to be taken in manually solving the problem
Ways of expressing an algorithm - Structured English – subset of English; has limited selection of sentences that reflect processing activities
- Pseudo code – notational system for algorithms that is a mixture of English and a programming language
- Flowchart – graphical representation of the order of execution of instructions
Advantages and Disadvantages Advantages - Programs run quickly
- System resources are used efficiently
- Classic approach
Disadvantages - Does not fit with complex algorithms
- Forces programmers to think of problems as a series of steps
Object-Oriented programming - Based on the idea that the solution for a problem can be visualized in terms of objects that interact
- Object – a unit of data that represents an abstract or real-world entity; from a class
- Class – a template for a group of objects with similar characteristics
More on Classes · UML (Unified Modeling Language) · Class attribute – defines the characteristics of a set of objects o Public attribute – available for use anywhere in the program o Private attribute – can only be accessed where it is defined · Inheritance – passing certain characteristics from one class to other classes · Super class – any class from which attributes can be inherited · Subclass – any class that inherits from a super class What is a Method? - A method is a segment of code that defines an action
- It can perform a variety of tasks such as collecting input, performing calculations, comparing data, and producing output
- Polymorphism – overloading; redefine a method in a subclass
Advantages and disadvantages Advantages - Similar to the way human beings see the world
- Allows encapsulation (hiding object details and methods) that lets objects be reused, modified and repurposed
Disadvantages - Requires more memory and processing resources
| | |
| |
You're a Wild Drunk
|
You can get enough drink. Seriously, you'll just go puke and start pounding them back again!
|
| | |
| |
You Should Get a MFA (Masters of Fine Arts)
|
You're a blooming artistic talent, even if you aren't quite convinced.
You'd make an incredible artist, photographer, or film maker.
|
| | |
| |
You Are 50% Boyish and 50% Girlish
|
You are pretty evenly split down the middle - a total eunuch.
Okay, kidding about the eunuch part. But you do get along with both sexes.
You reject traditional gender roles. However, you don't actively fight them.
You're just you. You don't try to be what people expect you to be.
|
| | |
| |
You Are a Chick Rocker!
|
You're living proof that chicks can rock
You're inspired by Joan Jett and the Donnas
And when you rock, you rock hard
(Plus, you get all the cute guy groupies you want!)
|
| | |
|
|