Ask A Scientist©

Computer Science Archive


Can you advise a high school Pascal teacher?

Index Key:   CSI020
Author:      Jmitchel
Subject:     Can you advise a high school Pascal teacher?
Text:        I am interested in hearing from professionals in the field about 
what you think is important for students in their pursuit of learning computer 
programming.  I teach Pascal to level I and level II (A and  AB) students in 
Virginia.  Students are always asking about 1) Documentation, 2) How much 
structure is necessary, and 3) Why should we avoid global variables in our 
programs, among other things. Also, do you have any good ideas for project-
type programs?  We  are moving towards case studies in our teaching and I do 
not have much to go on in this area.

Response #: 1 of 2
Author:     John Hawley
Text:       The 3 issues you mention depend STRONGLY on who is going to use 
the code you write.  If you are going to be the only user and you are only 
going to use the program for a while, then why not be quick and dirty.  Do not 
document, do not use structure, and make everything a global!  BUT, if you are 
writing code for someone else to use, especially if someone else needs to 
understand the code, or if you are writing it for yourself and it is something 
you will be  using and maybe modifying for a long time, THEN document. Use 
structured programming to enhance the code's readability and maintainability, 
and, as far as globals go, encapsulated data is one of the buzz terms from 
object-oriented programming.  For small software projects, I do not think it 
matters much as long as you do not run out of memory.

Response #: 2 of 2 
Author:     Arthur Smith
Text:       Regarding project type of programming, how about getting together 
with some of the science teachers there and arranging at least an optional 
experiment that requires programming, or a program that simulates some 
experiment. Computers are certainly used more in science than anywhere else.






Back to Computers Ask A Scientist Index
NEWTON Homepage Ask A Question

NEWTON is an electronic community for Science, Math, and Computer Science K-12 Educators.
Argonne National Laboratory, Division of Educational Programs, Harold Myron, Ph.D., Division Director.