Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Pascal, anyone?

Pascal, anyone?
Thread Tools
Dedicated MacNNer
Join Date: Feb 2001
Location: Huddersfield, UK
Status: Offline
Reply With Quote
Jun 15, 2001, 06:14 PM
 
Hi.

I'm starting college next year and I thought that I'd do a 1 year A/S level in computing to introduce myself to programming (if the course is good, I might do another year).

I have discovered that the preferred language at the college is Pascal (!?!) and would like to get a head-start on learning the language before September.

My first question is this: Can I write programs for Mac OS X in Pascal, and if so, where can I get the programming tools for this?

Secondly, does anyone know of any good resources for programming in Pascal?

I know that Pascal is certainly not the language of choice for many people here, but I don't really have a choice in the matter.

Thanks!
PM G4 DP 500 MHz, 768 Mb, DVD-ROM, 85 Gb, Mac OS X 10.3.9
PB G4 1.25 GHz, 512 Mb, DVD-R, 80 Gb, Mac OS X 10.4
     
Dedicated MacNNer
Join Date: Jan 2001
Location: Boulder, CO, USA
Status: Offline
Reply With Quote
Jun 15, 2001, 08:42 PM
 
Yikes.

I think your only hope may be MPW, which you'll have to run in Classic, if you want to use OSX. Further, I don't think you'll be able to make Carbon apps with it, as I believe it will only compile for the 68k. So it'll be Classic or OS9 for you.

Of course, there may be other Pascal compilers out there. I don't know. This page didn't have much that looked promising, though the GNU Pascal compiler might be worth a look. It says it's based on the GCC back-end, so if it were ported to X it may even compile for the PPC.


Yikes.
     
Dedicated MacNNer
Join Date: May 2001
Location: Edinburgh, UK
Status: Offline
Reply With Quote
Jun 17, 2001, 11:09 AM
 
CodeWarrior had support for Pascal although I think it was recently removed. Maybe you can pick up an old version somewhere if you can stand developing in classic.
     
Dedicated MacNNer
Join Date: Jun 2000
Location: Dundas, Ontario, Canada
Status: Offline
Reply With Quote
Jun 17, 2001, 12:26 PM
 
Pascal is still common in beginner programming courses because it is VERY easy to learn (It is my first language, learned it in grade 11 at school). In fact, I go to the University of Waterloo for computer science and, until a few years ago, they also used Pascal (now it is Java).
Since learning Pascal is damn easy and they will be teaching you anyway, it won't really require much thinking so you could probably start knowing nothing of the language.
If I were you, I would just start to learn C. C is almost as easy to learn as Pascal and only slightly less powerful (C doesn't have objects). C is also extended into Objective C and C++ which both g beyond Pascal in ability yet hold the C syntax. Even Java and Perl syntax resembles that of C while Pascal looks only like itself (and Modula-3, I think). It will be easy for you to learn Pascal after C but knowing C opens more doors.

That is my recommendation,
Jeff.
Spectral Class
"Shedding Light on Innovation"
     
Richyfp  (op)
Dedicated MacNNer
Join Date: Feb 2001
Location: Huddersfield, UK
Status: Offline
Reply With Quote
Jun 18, 2001, 02:17 PM
 
Thanks for your responses.

I see that Pascal is a dying (basically dead) language then! I can understand why the college would choose to introduce beginners to a simple, easy-to-learn language, but what's the point if it's not used anywhere?!? .

Anyway, now that I have decided to learn C, can someone direct me to a simple C tutorial and the programming tools I need to program in this language? I'm gonna have a search for a thread on this cos I'm sure there are loads, but a link would be good, please...

Thanks again!
PM G4 DP 500 MHz, 768 Mb, DVD-ROM, 85 Gb, Mac OS X 10.3.9
PB G4 1.25 GHz, 512 Mb, DVD-R, 80 Gb, Mac OS X 10.4
     
Mac Elite
Join Date: Jan 2001
Location: New York
Status: Offline
Reply With Quote
Jun 18, 2001, 06:09 PM
 
The apple devtools include gcc(command is cc) which is industry standard c compiler and you can even use project builder for development if you want. A great book is "The C Programming Language" by Brian W. Kernighan and Dennis M. Ritchie two of the three original inventors of the C language. The book covers everything that a 500 page books covers with better easier to understand explanations in 272 pages.
     
Mac Elite
Join Date: Mar 2001
Location: Provo, UT
Status: Offline
Reply With Quote
Jun 18, 2001, 08:47 PM
 
Gnu has a Pascal compiler.
http://didaktik.physik.uni-essen.de/~gnu-pascal/

I've not really checked it out and don't know if it comes with OSX devtools. Realistically though I wouldn't bother if I were you. I did the Pascal / Modula-2/3 thing way back in the day. However as I'm sure everyone else tells you, learning C or C++ will help you far more and is a vastly superior language. The only downside is that C pointers aren't quite as "hit you over the head" as in Pascal. Of course that is a benefit for a lot of people - I personally find C pointers much more intuitive, but that's me.

C really isn't that hard a language and realistically is very similar to Pascal in most areas. The only difference is that C has a more "terse" notation. i.e. || instead of OR, && instead of AND, {} instead of BEGIN END.
     
Richyfp  (op)
Dedicated MacNNer
Join Date: Feb 2001
Location: Huddersfield, UK
Status: Offline
Reply With Quote
Jun 19, 2001, 05:05 AM
 
Cheers everyone!

I'm definately going to look into C now, and almost certainly going to buy the book - I'll see if I can get hold of it in a bookstore this Saturday.

You've all been most helpful!

Richard
PM G4 DP 500 MHz, 768 Mb, DVD-ROM, 85 Gb, Mac OS X 10.3.9
PB G4 1.25 GHz, 512 Mb, DVD-R, 80 Gb, Mac OS X 10.4
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 09:51 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2