Principles Of Algorithm Design I
CSCI 1320 -  Tentative Schedule
 
 Class  Topic(s)  Reading Assignments 
& Handouts
 Laboratory 
Assignments 
1/15  Introduction To Class

Distribute Course Outline
Distrubute Questionnaire



ClassRoom System
Log Out Of  UNIX - To Win 2000
Create UNIX Accounts
Check E-Mail & Record Password


Log Out of  Win 2000 - To UNIX
Log Into UNIX With 
UserName & Password
Log Out UNIX


All But One User
Restart Win 2000

Add Printer For HAS-LabPrinterA


Go To Hicks Class Web Page
http://carme.trinity.edu/thicks
Go To  Schedule Page

Instruct To Print A Copy
UNIX & VI Tutorials For Next Class

 


Hardware 

Power Supply
Bus
Mother Board
IC Chip
Microprocessor
CPU - ALU 
SIMM / DIMM
Bit - Byte - KB - MB - GB
RAM - ROM
Keyboard 
ASCII

Input Device
Output Device
Monitor
Mouse
Keyboard

Floppy Drive
Hard Drive
Tape Drive
CD-R Drive - CD ROM
CD-RW Drive

Video Card
NIC - Network Card
Sound Card
Modem
A-To_D Card

Read Course Outline

Fill Out Questionnaire (Lab I-5 points)

Print - Introduction To UNIX - 
Bring To Next Lecture

Print - Introduction To VI - 
Bring To Next Lecture

Read Chapter 1 Of Text



Note For Those Missing Class
Telnet Requires That You Set Up A UNIX Account
[This New Account Will Have The Same UserName, but a Different Password!]

This New UNIX Account Must Be Created From A University Lab On Upper Campus!
Go To A University Lab - Log Into Windows
Double Click On My Network Places Desktop Icon
Double Click On "Entire Network Choice"
Double Click On " Microsoft Windows Network"
Double Click On CS Icon
Double Click On Sol Icon

Start Internet Explorer & Check Your Mail
http:\\exchange.trinity.edu
New Password Will Be Mailed To You!

Have One of the CS Majors Help If Needed
If  Mailed Password Does Not Work
Contact Dr. Howland Halsell 201C (999-7364)

Telnet From Off Campus is Disabled! 

 Complete - 
Questionnaire 
5 Pts

Will Turn In Questionnaire At Beginning Of Lecture.

Do Not Put Questionnaire In Wire-Band Binder!

1/17  CPU
Binary Numeration System
Machine Language
Assembly Language
High Level Language
Compiler
Interpreter
Source Code
Binary Code
Object Code

System Software
Operating System

Abstraction
Information Hiding
Encapsulation
Modularization
Reuse
Object-Oriented Design
Classes

Binary Counting
0,1,10,11,100,101,
110,111,1000

Bit
Byte
Character
KB
MB
GB


 ls, ls -l, ls -a, ls -al
clear
ls P*, ls *.jpg
cat
yppasswd
cp
mv
rm
rmdir
vi
man 
cd
mkdir
rmdir
man 

  Hardware Tutorial

 

 Hardware Lab

Work On UNIX Lab

1/22

Binary Count To 8

ls -l d rwx rwx rwx

First Program
Include Files
#include <iostream.h>
main()
Braces {} Bound Logic 
Output Stream 
cout << 
return 0;

Compile Program 
g++ ProgramName.cpp

Execute Program 
a.out

mkdir 1320
chmod 700 1320

Review UNIX

 ls, ls -l, ls -a, ls -al
clear
ls P*, ls *.jpg
cat
yppasswd
cp
mv
rm
rmdir
vi
man 
cd
mkdir
rmdir
man 

    UNIX Lab

VI Lab

1/24

 Putty Install & Configuration

Information Representation
char  (1 byte)
Binary Numeration System 
Base 2 (0,1)
Counting in Binary
short int (1+ byte)
int - (2+ bytes)
long int (4+ bytes)
Octal Numeration System
Base 8 (0,1,2,3,4,5,6,7)
Hexadecimal Numeration System
Base 16 (0,1,2,3,4,5,6,7,9,A,B,C,D,E,F)

Numerical Information Representation
Memory - short int
Sign Magnitude 
One's Complement
Two's Complement
Char - ASCII

Read pp 49-60 

 

Visual C++ Printing: Page SetUp & Font Selection

 

 

 

First Programs Lab

 Numeration Systems Lab
Due 1/31
Start It!

 

 

1/29  Putty Install & Configuration

Information Representation
char  (1 byte)
Binary Numeration System 
Base 2 (0,1)
Counting in Binary
short int (1+ byte)
int - (2+ bytes)
long int (4+ bytes)
Octal Numeration System
Base 8 (0,1,2,3,4,5,6,7)
Hexadecimal Numeration System
Base 16 (0,1,2,3,4,5,6,7,9,A,B,C,D,E,F)

Numerical Information Representation
Memory - short int
Sign Magnitude 
One's Complement
Two's Complement
Char - ASCII

   
1/31  

Comments // /*..  */
# include Directive
void main(int argc, char * argv[])
Braces { }
Variables

Minimal Range
short int x [127 <==> -128]
short int (1+ Bytes)
int x [32,767 <==> -32, 768]
 int (2+ Bytes)
long int x [2,147,483,647 <=
=> -2,147,483,648]
int (4+ Bytes)

unsigned int x [0 <==> 65,535]
unsigned short int x [0 <==> 255]
unsigned long int x [0 <=
=> 4,294,967,296]

char (1 Byte)
char x : ASCII 0-255
char x[3] (3 Bytes)
char x[25] (25  Bytes) 

float x [7 digits accuracy]
float (4+ Bytes)
double x [15 digits accuracy]
float (8+ Bytes)
long double x [19digits accuracy]
float (12+ Bytes)
Not Always Avail On All Compilers

Statements End ;
Declaration 
int x;
Assignment Statemtents =
Expression Statement
x = 15;
Declaration-Initialization
int x = 15;

Identifiers = Variable Names
Variable Naming - Cap First Letter
A-Z, a-z, _

Constants
const int x = 32000;

Output <iostream.h>
cout  << "Character Strings"
cout  << Variables/Constants
cout  << endl

Input <iostream.h>
cin >> x;
>> Input/Extraction Operator

int Division
float Division

Modulus %
12 % 7 = 5
12 % 3 = 0
12 % 5 = 2

x++ => x + 1
x-- => x - 1
x += 2 => x = x + 2
x -= 2 => x = x - 2
x *= 2 => x = x * 2
x /= 2 => x = x / 2
x %= 2 => x = x % 2

char Option = 'N';

Save A File To IBM Floppy
Print A File On IBM Network
Left Margin = 1.25 "

Decisions
if then
if then else
operators 
>, <, >=, <=, ==, !=

Order Of Operations
char Ch;
Ch = 'A';
Ch = 65;
int No;
No = 65;
No = 'A';

# include <math.h>
sqrt

Floating Point Nos 
Not Exact - Roundoff Errors

real division vs integer division
12/5
12./5, 12/5., 12./5.
float(12)/5, 12/float(5)
float(12)/float(5)
(float) 12) /5, 12/ (float) 5
(float) 12 / (float) 5

cout << int(3.3)
cout  << float (2)

Clear Console Screen
# include <stdlib.h>
   system ("clear");

 Read pp 61 - 82

  Read pp 103-120

  Read  pp 164-171 

 Payroll #0 Lab
2/5  

Display Stream Decimals
# include <iomanip.h>
cout.setf(ios::fixed);
cout.setf(ios::showpoint);
cout.precision(2);

Format Text
# include <iomanip.h>
cout << setw(10) << No;

Syntax Errors
Logic Errors
RunTime Errors

Decisions
if then
if then else
operators 
>, <, >=, <=, ==, !=

if ( condition)
      ----------

if ( condition)
      ----------
else 
      ----------
 

if ( condition)
   { 
         ----------
         ----------
    } 
else 
   { 
         ----------
         ----------
    } 
 

if ( condition)
   { 
         ----------
         ----------
    } 
else if ( condition)
  { 
         ----------
         ----------
    } 
else 
   { 
         ----------
         ----------     } 

  Decision Lab 
2/7  User Defined Functions
UCase Diagram
AreaTriangle Calculation System

void ClearScreen (void);
void Commercial (void);
void GetInfo (int & Height,
int & Width, int & TriangleNo);

Scope of Variables
Reference Variables
Read Chapter 6  PayRoll 2 Lab
Due 2/19/02

Study For Exam
2/12  void Calculate  (int Height,
int Width, float  & Area);

void Display  (int  Height,
int Width, int TriangleNo
float Area);

Phase In Modules
While Loop

Flowchart Logic
Review For Exam
 Study For Exam Study For Exam 
2/14 Exam I    
2/19 Fixed Repetition Loop 
for (init; condition; Process At End)
{......};

Review PostTest Loop
do { ....... ) while (condition);

Pretest Loop
while (condition) {......};

When To Use What Loops

 San Chapter 4  Loop Practice Lab
2/21  User Defined
Explicit Functions
Read Chapter 4 Carefully  
2/26  Nassi-Schneiderman Flowcharts

Program Design
Modularization

Review Explicit Functions

   Explicit Function Lab
2/28  Array Functions

Passing Arguments To Arrays
Array - ActNo - Max

Define & Fill

   Static Array Lab
3/5  Explicit Function SumIntArray
Review Arrays

Introduction To Classes

private:
public:


Encapsulation
Bundling Data & Methods 

Constructor

   
3/7  char Name[25];
string.h
strlen(String)
strcpy(OriginalString, NewString)
strcmp(OriginalString, NewString)
strcmp(FirstString, SecondString)

Introduction To Classes
class
{
private:

public:
};
Method
Constructor Methods
Destructor Methods
Set
Display
Get

Function Overloading
Multiple Constructors
 

   Book Class Lab
3/12   Spring Break    
3/14   Spring Break    
3/19 Classes Continued

Constructor
Destructor
Function Overloading

   Computer Class Lab
3/21 Dynamic Memory 
new
delete

long int * Nos;
Nos = new int [20];
delete [] Nos;
Nos[2] = 12211;
Nos[0] = 45;
Nos[9] = -211;

Dynamic Class
IntArray(long int NewMax);
~IntArray(void)

  Put Together class IntArray
with Constructor and Destructor.

Print & Bring To Lecture! 

Study For Exam

3/26  Dynamic vs Static Arrays    Study For Exam
3/28 Exam II    
4/2   Review Exam
Dynamic Memory
   Dynamic Array I Lab
4/4   Introduction To Sequential Files    
4/9  Reading & Writing Files    
4/11   Binary Search
Sequential Search
    Dynamic Array II Lab
Due By Thursday 4:00 Noon 4/18
4/16 Introduction To Recursion
1 - Call Itself
2- General Case That Can Be
Expressed In Terms Of A Simpler Case
3 - Trivial Case (Kick Out)

Stack - LIFO Array
Last In First Out
Push - Add To Stack
Pop - Remove From Stack
Empty - Tell If Empty

Using Stack To Explain Recursion
Function Fact

   
4/18  Recursion Continued

Fibonacci
StrOut

   Recursive Strings Lab
4/23   Break Program Into
.hpp and .cpp files
Makefile
make
 
Dell Makefile Lab
4/25      
4/30      
5/1 & 5/2 Reading Days    
5/6 8:30 Exam III      
There Will Be A Final Project!  There Will Not Be A Comprehensive Final Exam During Exam Week!
doctype html public "-//w3c//dtd html 4.0 transitional//en"> Tentative Schedule [CSCI 1320] - Dr. Thomas E. Hicks  
CSC I 1320 -  Tentative Schedule
 
 Class  Topic(s)  Reading Assignments 
& Handouts
 Laboratory 
Assignments 
1/15  Introduction To Class

Distribute Course Outline
Distrubute Questionnaire



ClassRoom System
Log Out Of  UNIX - To Win 2000
Create UNIX Accounts
Check E-Mail & Record Password


Log Out of  Win 2000 - To UNIX
Log Into UNIX With 
UserName & Password
Log Out UNIX


All But One User
Restart Win 2000

Add Printer For HAS-LabPrinterA


Go To Hicks Class Web Page
http://carme.trinity.edu/thicks
Go To  Schedule Page

Instruct To Print A Copy
UNIX & VI Tutorials For Next Class

 


Hardware 

Power Supply
Bus
Mother Board
IC Chip
Microprocessor
CPU - ALU 
SIMM / DIMM
Bit - Byte - KB - MB - GB
RAM - ROM
Keyboard 
ASCII

Input Device
Output Device
Monitor
Mouse
Keyboard

Floppy Drive
Hard Drive
Tape Drive
CD-R Drive - CD ROM
CD-RW Drive

Video Card
NIC - Network Card
Sound Card
Modem
A-To_D Card

Read Course Outline

Fill Out Questionnaire (Lab I-5 points)

Print - Introduction To UNIX - 
Bring To Next Lecture

Print - Introduction To VI - 
Bring To Next Lecture

Read Chapter 1 Of Text



Note For Those Missing Class
Telnet Requires That You Set Up A UNIX Account
[This New Account Will Have The Same UserName, but a Different Password!]

This New UNIX Account Must Be Created From A University Lab On Upper Campus!
Go To A University Lab - Log Into Windows
Double Click On My Network Places Desktop Icon
Double Click On "Entire Network Choice"
Double Click On " Microsoft Windows Network"
Double Click On CS Icon
Double Click On Sol Icon

Start Internet Explorer & Check Your Mail
http:\\exchange.trinity.edu
New Password Will Be Mailed To You!

Have One of the CS Majors Help If Needed
If  Mailed Password Does Not Work
Contact Dr. Howland Halsell 201C (999-7364)

Telnet From Off Campus is Disabled! 

 Complete - 
Questionnaire 
5 Pts

Will Turn In Questionnaire At Beginning Of Lecture.

Do Not Put Questionnaire In Wire-Band Binder!

1/17  CPU
Binary Numeration System
Machine Language
Assembly Language
High Level Language
Compiler
Interpreter
Source Code
Binary Code
Object Code

System Software
Operating System

Abstraction
Information Hiding
Encapsulation
Modularization
Reuse
Object-Oriented Design
Classes

Binary Counting
0,1,10,11,100,101,
110,111,1000

Bit
Byte
Character
KB
MB
GB


 ls, ls -l, ls -a, ls -al
clear
ls P*, ls *.jpg
cat
yppasswd
cp
mv
rm
rmdir
vi
man 
cd
mkdir
rmdir
man 

  Hardware Tutorial

 

 Hardware Lab

Work On UNIX Lab

1/22

Binary Count To 8

ls -l d rwx rwx rwx

First Program
Include Files
#include <iostream.h>
main()
Braces {} Bound Logic 
Output Stream 
cout << 
return 0;

Compile Program 
g++ ProgramName.cpp

Execute Program 
a.out

mkdir 1320
chmod 700 1320

Review UNIX

 ls, ls -l, ls -a, ls -al
clear
ls P*, ls *.jpg
cat
yppasswd
cp
mv
rm
rmdir
vi
man 
cd
mkdir
rmdir
man 

    UNIX Lab

VI Lab

1/24

 Putty Install & Configuration

Information Representation
char  (1 byte)
Binary Numeration System 
Base 2 (0,1)
Counting in Binary
short int (1+ byte)
int - (2+ bytes)
long int (4+ bytes)
Octal Numeration System
Base 8 (0,1,2,3,4,5,6,7)
Hexadecimal Numeration System
Base 16 (0,1,2,3,4,5,6,7,9,A,B,C,D,E,F)

Numerical Information Representation
Memory - short int
Sign Magnitude 
One's Complement
Two's Complement
Char - ASCII

Read pp 49-60 

 

Visual C++ Printing: Page SetUp & Font Selection

 

 

 

First Programs Lab

 Numeration Systems Lab
Due 1/31
Start It!

 

 

1/29  Putty Install & Configuration

Information Representation
char  (1 byte)
Binary Numeration System 
Base 2 (0,1)
Counting in Binary
short int (1+ byte)
int - (2+ bytes)
long int (4+ bytes)
Octal Numeration System
Base 8 (0,1,2,3,4,5,6,7)
Hexadecimal Numeration System
Base 16 (0,1,2,3,4,5,6,7,9,A,B,C,D,E,F)

Numerical Information Representation
Memory - short int
Sign Magnitude 
One's Complement
Two's Complement
Char - ASCII

   
1/31  

Comments // /*..  */
# include Directive
void main(int argc, char * argv[])
Braces { }
Variables

Minimal Range
short int x [127 <==> -128]
short int (1+ Bytes)
int x [32,767 <==> -32, 768]
 int (2+ Bytes)
long int x [2,147,483,647 <=
=> -2,147,483,648]
int (4+ Bytes)

unsigned int x [0 <==> 65,535]
unsigned short int x [0 <==> 255]
unsigned long int x [0 <=
=> 4,294,967,296]

char (1 Byte)
char x : ASCII 0-255
char x[3] (3 Bytes)
char x[25] (25  Bytes) 

float x [7 digits accuracy]
float (4+ Bytes)
double x [15 digits accuracy]
float (8+ Bytes)
long double x [19digits accuracy]
float (12+ Bytes)
Not Always Avail On All Compilers

Statements End ;
Declaration 
int x;
Assignment Statemtents =
Expression Statement
x = 15;
Declaration-Initialization
int x = 15;

Identifiers = Variable Names
Variable Naming - Cap First Letter
A-Z, a-z, _

Constants
const int x = 32000;

Output <iostream.h>
cout  << "Character Strings"
cout  << Variables/Constants
cout  << endl

Input <iostream.h>
cin >> x;
>> Input/Extraction Operator

int Division
float Division

Modulus %
12 % 7 = 5
12 % 3 = 0
12 % 5 = 2

x++ => x + 1
x-- => x - 1
x += 2 => x = x + 2
x -= 2 => x = x - 2
x *= 2 => x = x * 2
x /= 2 => x = x / 2
x %= 2 => x = x % 2

char Option = 'N';

Save A File To IBM Floppy
Print A File On IBM Network
Left Margin = 1.25 "

Decisions
if then
if then else
operators 
>, <, >=, <=, ==, !=

Order Of Operations
char Ch;
Ch = 'A';
Ch = 65;
int No;
No = 65;
No = 'A';

# include <math.h>
sqrt

Floating Point Nos 
Not Exact - Roundoff Errors

real division vs integer division
12/5
12./5, 12/5., 12./5.
float(12)/5, 12/float(5)
float(12)/float(5)
(float) 12) /5, 12/ (float) 5
(float) 12 / (float) 5

cout << int(3.3)
cout  << float (2)

Clear Console Screen
# include <stdlib.h>
   system ("clear");

 Read pp 61 - 82

  Read pp 103-120

  Read  pp 164-171 

 Payroll #0 Lab
2/5  

Display Stream Decimals
# include <iomanip.h>
cout.setf(ios::fixed);
cout.setf(ios::showpoint);
cout.precision(2);

Format Text
# include <iomanip.h>
cout << setw(10) << No;

Syntax Errors
Logic Errors
RunTime Errors

Decisions
if then
if then else
operators 
>, <, >=, <=, ==, !=

if ( condition)
      ----------

if ( condition)
      ----------
else 
      ----------
 

if ( condition)
   { 
         ----------
         ----------
    } 
else 
   { 
         ----------
         ----------
    } 
 

if ( condition)
   { 
         ----------
         ----------
    } 
else if ( condition)
  { 
         ----------
         ----------
    } 
else 
   { 
         ----------
         ----------     } 

  Decision Lab 
2/7  User Defined Functions
UCase Diagram
AreaTriangle Calculation System

void ClearScreen (void);
void Commercial (void);
void GetInfo (int & Height,
int & Width, int & TriangleNo);

Scope of Variables
Reference Variables
Read Chapter 6  PayRoll 2 Lab
Due 2/19/02

Study For Exam
2/12  void Calculate  (int Height,
int Width, float  & Area);

void Display  (int  Height,
int Width, int TriangleNo
float Area);

Phase In Modules
While Loop

Flowchart Logic
Review For Exam
 Study For Exam Study For Exam 
2/14 Exam I    
2/19 Fixed Repetition Loop 
for (init; condition; Process At End)
{......};

Review PostTest Loop
do { ....... ) while (condition);

Pretest Loop
while (condition) {......};

When To Use What Loops

 San Chapter 4  Loop Practice Lab
2/21  User Defined
Explicit Functions
Read Chapter 4 Carefully  
2/26  Nassi-Schneiderman Flowcharts

Program Design
Modularization

Review Explicit Functions

   Explicit Function Lab
2/28  Array Functions

Passing Arguments To Arrays
Array - ActNo - Max

Define & Fill

   Static Array Lab
3/5  Explicit Function SumIntArray
Review Arrays

Introduction To Classes

private:
public:


Encapsulation
Bundling Data & Methods 

Constructor

   
3/7  char Name[25];
string.h
strlen(String)
strcpy(OriginalString, NewString)
strcmp(OriginalString, NewString)
strcmp(FirstString, SecondString)

Introduction To Classes
class
{
private:

public:
};
Method
Constructor Methods
Destructor Methods
Set
Display
Get

Function Overloading
Multiple Constructors
 

   Book Class Lab
3/12   Spring Break    
3/14   Spring Break    
3/19 Classes Continued

Constructor
Destructor
Function Overloading

   Computer Class Lab
3/21 Dynamic Memory 
new
delete

long int * Nos;
Nos = new int [20];
delete [] Nos;
Nos[2] = 12211;
Nos[0] = 45;
Nos[9] = -211;

Dynamic Class
IntArray(long int NewMax);
~IntArray(void)

  Put Together class IntArray
with Constructor and Destructor.

Print & Bring To Lecture! 

Study For Exam

3/26  Dynamic vs Static Arrays    Study For Exam
3/28 Exam II    
4/2   Review Exam
Dynamic Memory
   Dynamic Array I Lab
4/4   Introduction To Sequential Files    
4/9  Reading & Writing Files    
4/11   Binary Search
Sequential Search
    Dynamic Array II Lab
Due By Thursday 4:00 Noon 4/18
4/16 Introduction To Recursion
1 - Call Itself
2- General Case That Can Be
Expressed In Terms Of A Simpler Case
3 - Trivial Case (Kick Out)

Stack - LIFO Array
Last In First Out
Push - Add To Stack
Pop - Remove From Stack
Empty - Tell If Empty

Using Stack To Explain Recursion
Function Fact

   
4/18  Recursion Continued

Fibonacci
StrOut

   Recursive Strings Lab
4/23   Break Program Into
.hpp and .cpp files
Makefile
make
 
Dell Makefile Lab
4/25      
4/30      
5/1 & 5/2 Reading Days    
5/6 8:30 Exam III      
There Will Be A Final Project!  There Will Not Be A Comprehensive Final Exam During Exam Week!