Skip to content

Turbo Pascal version 1.0 - Common Questions

Here are a few of the frequently asked questions about Turbo Pascal.  These questions are taken from the Turbo Pascal manual, Turbo Tutor book, from the Internet, and also from my (not-so-complete) memory.

Q: Who were the developers who originally worked on the Turbo Pascal version 1.0 software, manuals, and examples? A: Anders Hejlsberg (compiler, runtime library), Ole Paulsen (Wordstar-like editor), Mogens Glad (memory management and integration of the editor, runtime, and compiler), Lars Frid-Nielsen (runtime library functions), Ole Henriksen (manual with examples) and Philippe Kahn (Turbo Pascal IDE design and functional prototype written using Digital Research’s Pascal MT+, MicroCalc Pascal spreadsheet example).

Q: How much RAM do I need to run Turbo Pascal?  A: You’ll need at least 48k on a CP/M-80 machine and 128k on a 16-bit or PC-compatible machine. Turbo Pascal version 1.0 produces .com files that can use 64K maximum for code, data and the stack.

Q: What was the license agreement for the use of Turbo Pascal?  A: Turbo Pascal version 1.0 (and version 2.0) came with a license agreement that states allowed it’s use on a single computer when the purchaser sent in the registration card that was inside the manual. The original license text:

    Single CPU License
    The price paid for one copy of TURBO Pascal licenses you to use the product on one CPU when and only when you have signed and returned the License Agreement printed in this book.

Many developers will refer to the "Borland No-Nonsense License Statement".  This license statement first appeared in the original Turbo Pascal Turbo Tutor manual in 1984 and then appeared in Turbo Pascal compiler versions starting with Turbo Pascal version 3.0. The no-nonsense license statement text read

    Borland’s No-Nonsense License Statement
    This software is protected by both United States Copyright Law and International Treaty provisions. Therefore, you must treat this software just like a book with the following single exception. Borland International autorizes you to make archival copies of the sofware for the sole purpose of backing up your software and protecting your investment from loss.
    By saying, just like a book, Borland means, for example, that this software may be used by any number of people and may be freely moved from one computer location to another - so long as there is NO POSSIBILITY of it being used at one location while it’s being used at another. Just like a book that can’t be read by two different people in two different places at the same time, neither can the software be used by two different people in two different places at the same time.

Q: How do I assign an integer variable a value of -32768? A: By assigning the integer a value of $8000.

Q: What is the maximum length of a string in Turbo Pascal?  A:  255 characters.

Q: When I use FillChar on a string, the string gets messed up.  Why?  A: Rember that the zero’th buye of a string is used to hold the current length of the string.  Immediately after using the FillChar routine, you must be sure to set he length byte of your string to the appropriate value.

Q: I can’t get Turbo Pascal to load on my DEC Rainbow PC.  Why?  A: Make sure you are using the DEC format, not the MS-DOS format.

Q: Can I use the progam I developed under CP/M-80 on my IBM PC? A: Yes, you can, provided there are no machine-specific calls in your code and that you recompile the source code on an IBM PC implementation of Turbo Pascal.

Q: How can I use Turbo Pascal to write to DOS’s null device?  A: Use the following code:

    program WriteToNul;
    var T : text;
    begin
      Assign(T,'Nul');
      Rewrite(T);
      Writeln(T,'help');
      Close(T);
    end.

Q: How do you hide the cursor using Turbo Pascal?  A:  The following program shows how to turn the cursor on and off in Turbo Pascal:

    program  HideCursor;
    procedure SetCursor(On:boolean);
    var
      reg : record
        ax,bx,cx,dx,bp,si,di,ds,es,flags : integer
      end;
    begin
      with reg do
      begin
        if On then   { turn cursor on }
          cx := $C0B { $706 if on color monitor }
        else
          cx := $20;
        bx := 0;
        ax := $0100;
      end;  { with }
      intr($10,reg);
    end;  { procedure SetCursor }
    begin
      SetCursor(false);
      Writeln('Cursor is hidden');
      Readln;
      SetCursor(true);
      Writeln('Cursor is visible');
      Readln
    end.

There are many additional sources of Turbo Pascal (and Borland Pascal) information and answers to questions. The following are just a few of the many online resources:

Post a Comment

Your email is never published nor shared. Required fields are marked *

Bad Behavior has blocked 4 access attempts in the last 7 days.

Close