home *** CD-ROM | disk | FTP | other *** search
/ ProfitPress Mega CDROM2 …eeware (MSDOS)(1992)(Eng) / ProfitPress-MegaCDROM2.B6I / PROG / PASCAL / PASTUT24.ZIP / PTUTRTXT.ZIP / TABCONT.TXT < prev   
Encoding:
Text File  |  1989-12-01  |  9.8 KB  |  239 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.                     CORONADO ENTERPRISES
  9.  
  10.               TURBO PASCAL TUTOR - Version 2.4
  11.  
  12.  
  13.  
  14. This documentation and the accompanying software, including all
  15. of the example Pascal programs and text files, are protected
  16. under United States copyright law to protect them from unauth-
  17. orized commercialization.  This version of the tutorial is dis-
  18. tributed under the shareware concept, which means you are not
  19. required to pay for it.  You are permitted to copy the disks,
  20. and pass the copies on to a friend, provided that you do not
  21. modify any files or omit any files from the complete package,
  22. and you are in fact encouraged to pass on complete copies to
  23. friends.  You are permitted to charge a small fee to cover the
  24. costs of duplication, but you are not permitted to charge any-
  25. thing for the software itself.
  26.  
  27. If you find the tutorial helpful, you are encouraged to register
  28. with the author and to submit a small fee to help compensate him
  29. for his time and expense in writing it.  We will provide you
  30. with a beautifully printed copy of this tutorial if you submit a
  31. full registration.  See the READ.ME file on either diskette for
  32. additional details.
  33.  
  34. Whether or not you send a registration fee, feel free to request
  35. a copy of the latest list of available tutorials and a list of
  36. the authorized Public Domain libraries that distribute our full
  37. line of programming language tutorials.
  38.  
  39.  
  40.                 Gordon Dodrill - Dec 1, 1989
  41.  
  42.  
  43.  
  44.        Copyright (c) 1988, 1989 Coronado Enterprises
  45.  
  46.  
  47.                    Coronado Enterprises
  48.                    12501 Coronado Ave NE
  49.                Albuquerque, New Mexico 87122
  50.  
  51.  
  52.  
  53.           TURBO PASCAL TUTORIAL - TABLE OF CONTENTS
  54.  
  55.  
  56. Introduction to the TURBO Pascal tutorial            Page I-1
  57.  
  58. Chapter 1 - What is a computer program?              Page 1-1
  59.  
  60.  
  61. Chapter 2 - Getting started in Pascal.               Page 2-1
  62.  
  63.      TRIVIAL.PAS     The minimum Pascal program.       2-1
  64.      WRITESM.PAS     Write something out.              2-3
  65.      WRITEMR.PAS     Write more out.                   2-4
  66.      PASCOMS.PAS     Pascal comments illustration.     2-4
  67.      GOODFORM.PAS    Good formatting example.          2-6
  68.      UGLYFORM.PAS    Ugly formatting example.          2-6
  69.  
  70. Chapter 3 - The simple Pascal data types.            Page 3-1
  71.  
  72.      INTVAR.PAS      Integer variables.                3-2
  73.      INTVAR2.PAS     More integer variables.           3-3
  74.      ALLVAR.PAS      All simple variable types.        3-4
  75.      REALMATH.PAS    Real variable math example.       3-4
  76.      INTMATH.PAS     Integer variable math example.    3-4
  77.      BOOLMATH.PAS    Boolean variable math example.    3-5
  78.      CHARDEMO.PAS    Character variable demonstration. 3-6
  79.      CONVERT.PAS     Data type conversion.             3-7
  80.      NEWINT4.PAS     New integer types, ver 4.0 & 5.x  3-7
  81.      NEWREAL4.PAS    New real types, ver 4.0 & 5.x     3-8
  82.  
  83. Chapter 4 - Pascal loops and control structures.     Page 4-1
  84.  
  85.      LOOPDEMO.PAS    Loop demonstration.               4-1
  86.      IFDEMO.PAS      Conditional branching.            4-2
  87.      LOOPIF.PAS      Loops and If's together.          4-3
  88.      TEMPCONV.PAS    Temperature conversion.           4-4
  89.      DUMBCONV.PAS    Poor variable names.              4-4
  90.      REPEATLP.PAS    Repeat until structure.           4-4
  91.      WHILELP.PAS     While structure.                  4-5
  92.      CASEDEMO.PAS    Case demonstration.               4-5
  93.      BIGCASE.PAS     Bigger case example               4-6
  94.  
  95. Chapter 5 - Pascal procedures and functions.         Page 5-1
  96.  
  97.      PROCED1.PAS     Simple procedures.                5-1
  98.      PROCED2.PAS     Procedures with variables.        5-4
  99.      PROCED3.PAS     Multiple variables.               5-6
  100.      PROCED4.PAS     Scope of variables.               5-7
  101.      PROCED5.PAS     Procedure calling procedures.     5-8
  102.      FUNCTION.PAS    An example function.              5-8
  103.      RECURSON.PAS    An example with recursion.        5-9
  104.      FORWARD.PAS     The forward reference.            5-10
  105.      PROCTYPE.PAS    The procedure type                5-10
  106.      FUNCTYPE.PAS    The function type                 5-11
  107.  
  108.  
  109.  
  110.  
  111. Chapter 6 - Arrays, types, constants, & labels.      Page 6-1
  112.  
  113.      ARRAYS.PAS      Simple arrays.                    6-1
  114.      ARRAYS2.PAS     Multiple arrays.                  6-2
  115.      TYPES.PAS       Example of types.                 6-3
  116.      CONSTANT.PAS    Example of constants.             6-5
  117.      LABELS.PAS      Label illustration.               6-6
  118.  
  119. Chapter 7 - Strings and string procedures.           Page 7-1
  120.  
  121.      STRARRAY.PAS   Pascal strings.                    7-1
  122.      STRINGS.PAS    TURBO Pascal strings.              7-2
  123.      WHATSTRG.PAS   What is a string?                  7-2
  124.  
  125. Chapter 8 - Scalars, subranges, and sets.            Page 8-1
  126.  
  127.      ENTYPES.PAS    Enumerated types.                  8-1
  128.      SUBRANGE.PAS   Scaler operations.                 8-2
  129.      SETS.PAS       Set operations.                    8-4
  130.      FINDCHRS.PAS   Search for characters.             8-5
  131.  
  132. Chapter 9 - Records.                                 Page 9-1
  133.  
  134.      SMALLREC.PAS   A small record example.            9-1
  135.      BIGREC.PAS     A large record example.            9-2
  136.      VARREC.PAS     A variant record example.          9-5
  137.  
  138. Chapter 10 - Standard Input/Output.                  Page 10-1
  139.  
  140.      WRITELNX.PAS   Generalized output statements.     10-1
  141.      READINT.PAS    Read integers from keyboard.       10-2
  142.      READREAL.PAS   Read reals from keyboard.          10-3
  143.      READCHAR.PAS   Read characters from keyboard.     10-4
  144.      READARRY.PAS   Read an array from keyboard.       10-4
  145.      READSTRG.PAS   Read a string from keyboard.       10-4
  146.      PRINTOUT.PAS   Print some data on the printer.    10-5
  147.  
  148. Chapter 11 - Files.                                  Page 11-1
  149.  
  150.      READFILE.PAS   Read and display this file.        11-2
  151.      READDISP.PAS   Read and display any file.         11-3
  152.      READSTOR.PAS   Read and store any file.           11-4
  153.      READINTS.PAS   Read an integer data file.         11-6
  154.      INTDATA.TXT    Integer data file.                 11-6
  155.      READDATA.PAS   Read a mixed data file.            11-7
  156.      REALDATA.TXT   Real data file.                    11-8
  157.      BINOUT.PAS     Write a binary file.               11-8
  158.      BININ.PAS      Read a binary file.                11-10
  159.  
  160.  
  161.  
  162. Chapter 12 - Pointers and dynamic allocation.        Page 12-1
  163.  
  164.      POINT.PAS      First pointer example              12-1
  165.      POINT4.PAS     Pointers with ver 4.0 & 5.x        12-3
  166.      POINTERS.PAS   Example program with pointers.     12-3
  167.      DYNREC.PAS     Dynamic record allocation.         12-5
  168.      LINKLIST.PAS   An example linked list.            12-7
  169.  
  170. Chapter 13 - Units in TURBO Pascal 4.0 & 5.x         Page 13-1
  171.  
  172.      AREAS.PAS      Areas of geometric shapes.         13-1
  173.      PERIMS.PAS     Perimeters of geometric shapes.    13-4
  174.      GARDEN.PAS     User of above units.               13-4
  175.      SHAPES4.PAS    User of above units.               13-5
  176.  
  177. Chapter 14 - Complete example programs.              Page 14-1
  178.  
  179.      AMORT1.PAS     Start of amortization program.     14-1
  180.      AMORT2.PAS     Better amortization program.       14-1
  181.      AMORT3.PAS     Useable amortization program.      14-1
  182.      AMORT4.PAS     Neat amortization program.         14-1
  183.      AMORT5.PAS     Complete amortization program.     14-2
  184.      LIST3.PAS      List Pascal programs (ver 3.0).    14-3
  185.      LIST4.PAS      List Pascal programs (ver 4 & 5).  14-3
  186.      LIST.EXE       Ready to use list program.         14-3
  187.      TIMEDATE.PAS   Get time and date (ver 3.0).       14-4
  188.      TIMEDAT4.PAS   Get time and date (ver 4 & 5).     14-4
  189.      SETTIME.PAS    Set a file's time and date.        14-4
  190.      SHAPES3.PAS    Calculate areas of shapes.         14-4
  191.      OT3.PAS        Directory list (ver 3.0).          14-5
  192.      OT4.PAS        Directory list (ver 4 & 5).        14-5
  193.      OT.DOC         How to use OakTree.                14-5
  194.  
  195. Chapter 15 - Encapsulation and Inheritance           Page 15-1
  196.  
  197.      ENCAP1.PAS     First Encapsulation.               15-1
  198.      ENCAP2.PAS     More Encapsulation.                15-5
  199.      INHERIT1.PAS   First Inheritance.                 15-7
  200.      VEHICLES.PAS   An Object in a Unit.               15-9
  201.      CARTRUCK.PAS   Descendant Objects.                15-10
  202.      INHERIT2.PAS   Inheritance in Use.                15-10
  203.      INHERIT3.PAS   Pointers and Arrays.               15-10
  204.  
  205. Chapter 16 - Virtual Methods                         Page 16-1
  206.  
  207.      VIRTUAL1.PAS   No Virtual Yet.                    16-1
  208.      VIRTUAL2.PAS   Virtual Methods in Use.            16-2
  209.      VIRTUAL3.PAS   Virtuals and Pointers.             16-4
  210.      PERSON.PAS     An Ancestor Object.                16-4
  211.      SUPERVSR.PAS   Descendant Objects.                16-5
  212.      EMPLOYEE.PAS   Using Virtual Methods.             16-5
  213.  
  214.  
  215.  
  216.  
  217.  
  218.  
  219.  
  220.  
  221. ABOUT THE AUTHOR
  222. ___________________________________________________________
  223.  
  224. The author of this tutorial began programming in 1961 using
  225. FORTRAN on an IBM 1620.  Since then, most of his career has
  226. been involved with designing digital logic for satellite
  227. application.  In 1983, being somewhat burned out with logic
  228. design, he began a study of some of the more modern
  229. programming languages and has since made a complete career
  230. shift to software development.  After learning Pascal, C was
  231. studied, followed by Modula-2 and Ada, and more recently C++.
  232. Rather than simply learning the syntax of each new language, 
  233. modern methods of software engineering were studied and 
  234. applied to effectively utilize the languages.  He is current-
  235. ly employed by a large research and development laboratory
  236. where he continues to study, teach, and apply the newer 
  237. programming languages.
  238.  
  239.