Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: Turbo Pascal

  1. #1
    Senior Member
    Join Date
    Jul 2002
    Posts
    154

    Turbo Pascal

    Here we go.

  2. #2
    This counts as a tutorial??

  3. #3
    Banned
    Join Date
    Jul 2002
    Posts
    877
    I dunno what "turbo"pascal is like but actually ChrisWuk, I would consider this to be a tutorial. It shows the basics of a small hello world type program. Though it is very small its enought to get used to the structure of some of the sub programs used in pascal. You see in the 80s all you needed to do was measure what size & position you want everything to be in, then type your code into a text-editor, after that compile and run. If this were.... ummm... lets say VC++ or VB he would have probably writen 10 pages on where to point and click, or how to drag, drop, & code or where to find some menu to change the properties and componets...

    If your a PC book junkie like I am you'll also notice that almost all beginers' programing guides/books start out with explaining how sub programs & functions work then how to make some type of a hello world program like this one.

  4. #4
    I think that is a tutorial ,thats good for a newbe ....

  5. #5
    Senior Member
    Join Date
    Jul 2002
    Posts
    744
    I had to take a class in Turbo Pascal. . .horrible prof so I didn' retain all that much, but I remember that we had to use 'writeln' for output. . .are there some header includes that allow you to use just write?? Well I'm sure there are, but what are they, please??
    Every now and then, one of you won't annoy me.

  6. #6
    Senior Member
    Join Date
    Mar 2003
    Location
    central il
    Posts
    1,779
    Pascal and therefore turbo Pascal are considered learning languages, as such they are a little limited, you cant include anything. There is no include statement, no header files ect.

    The way we reused code in Pascal was to create a file with useful code bits and then copy and paste into programs

    so unless you want to create a new print statement (using writeln) you are stuck with it.

  7. #7
    Senior Member
    Join Date
    Jul 2002
    Posts
    744
    See, ya know that's what I thought, but he just uses write() in his example.. .hmmmm, oh well. So the tut should actually read

    Begin
    WriteLn ('Hello World');
    End.

    Every now and then, one of you won't annoy me.

  8. #8
    Senior Member
    Join Date
    Jul 2002
    Posts
    154
    'writeln' for output
    Writeln and write do the same thing except that writeln will go to the next line, and write will just keep spitting stuff out in one line. Writeln is good if you're writing a paragraph, and don't want pascal to cut off your sentences, so you cut them off yourself. But, I was writing one line here so I used write instead of writeln.
    you cant include anything. There is no include statement, no header files ect.
    Ah, the beauty of pascal. Everything relies on the compiler, and there are many of them. I believe the latest version is Turbo Pascal 7, and it does allow you to include files. I'm fairly sure of that, I've heard of people doing that. I still have to try it, I just don't use Turbo Pascal 7, but I'm hoping to check that out soon.

  9. #9
    Senior Member
    Join Date
    Jul 2002
    Posts
    744
    Ah ha, kewl, thanks for giving me the answer to my question.
    Every now and then, one of you won't annoy me.

  10. #10
    Junior Member
    Join Date
    Mar 2003
    Posts
    7
    Geeze... I feel I don't understand something...

    All my life I've been including files (USES directive), and I didn't try not using it. I thought that's obligatory...

    Anyway, I'm up to Cpp now, so I won't try to not-use USES (he-he).

    By the way, the latest ver is (I suppose) v7.1. Procs with PII (or higher) architecture can't use TP v7.0 because of a VERY serious bug. So, if ye need a Pascal compilator on a PII or some Duron, you'll just HAVE to use v7.1. Just in case somebody didn't know.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •