PDA

View Full Version : Were to start?



moonblade
31-05-2007, 10:35 AM
First... What is the difference between Delphi and Pascal?

I want to learn, but were do I start and with what?

Is this hard to learn? Ofcourse you say: "No! it's very easy!"
But my experience tells me that that is what they all say. No matter who you ask the all say, about the language they know, that is the most easy to learn. :wink:

So were to go, what to do?! :D

M.

Huehnerschaender
31-05-2007, 11:03 AM
Pascal is the name of a programming language.

Delphi is the name of an IDE/Compiler for Pascal (Object Pascal).

If you want to start learning Pascal using Delphi, you should search the net for tutorials for beginners. I think a quick google with "tutorial Delphi Beginner" will popup thousands of links.

savage
31-05-2007, 11:04 AM
Hi Moonblade and welcome to PGD.

Delphi is based on Pascal, but Delphi is possibly more accurately labelled Object Pascal, and thus allows you to use the Object Oriented paradigm if you wish.

Firstly, do you have any programming experience at all?

moonblade
31-05-2007, 11:12 AM
Thanks.

Yes, I have experience with c/c++, c#, VB05, java and PHP.

I am not an expert in any of them, but PHP is a favorite, and also the language I am strongest in.

M.

jasonf
31-05-2007, 11:14 AM
Tricky question "Where to start"...

It all depends on "Where are you at the moment?".

First off, Delphi and Pascal.
Pascal is the language, it's been around for donkeys years.. if you want to learn a little more about the language, try here http://en.wikipedia.org/wiki/Pascal_%28programming_language%29
It's a very nice, structured and clean language although when compared to some of the more recent languages, some may say it's a little inflexible.. but everyone to their own. I personally like the structured approach as it forces me to think before I act.

Delphi on the other hand is Borland's IDE and compiler for Object Pascal. Delphi has evolved over the years in terms of functionallity, target audience and price. The compiler is generally regarded as very good and efficient . But in the end, it's just an IDE with built in compiler, albeit a good one.

There are many flavours of Delphi to choose from, you can purshase the full version of the Borland development studio or you can opt for the free Delphi Explorer version.

Alternatives to Delphi do exist and some people on here use them wholly in preference to Borland's offering. The Lazarus IDE and Free Pascal compiler are quite mature these days and offer additional thing which the borland compiler simply can't do.. such as language enhancements and more importantly for some, Cross platform compilation..

Where to start also begs the question of "Where do you want to go?"
Just like many other languages, Pascal is very flexible and much effort has been done over the last several years to bring technology which was once the reserve for C programmers to the Pascal fold. Technologies like DirectX, SDL, OpenGL, more recently opening up console development. All is within reach. Wrappers and components exist for DirectX and OpenGL, so you need to know what you want to do.

I'd start by picking up a book on Pascal from the library and working through some of the examples inside.. then I'd get in the internet and search for more specific examples of the technologies I'd chosen. But getting a good understanding of the language would be my first port of call.

Pascal is neither hard nor easy to learn, it all depends on you really. It's a structured language. It will teach you good programming principles if you care to learn them. It depends on how much effort you want to put into learning.
You could of course learn C, it's a great language with support throughout the industry, but as most C newbies will tell you, it's very easy to get in over your head and get into some real trouble without seeming to accomplish anything. Pascal takes away (or puts to one side) the problem with pointers so you can write code without falling into the many pitfalls which plague novice C programmers.. I should know, I was one once.

Whatever you do, you'll be able to get help on this site as long as you are prepared to put the effort in yourself too. There's a lot of knowledge and respect waiting to be earned.

I wish you the best.

moonblade
31-05-2007, 11:25 AM
Thanks Jason!
Very helpfull...

And yes, that was also my problem with C, and I learned that it wasn't different with C++, still one big syntaxerror. :wink:

But what I am doing is searching for the right language for me, something that makes me tick, and makes me want more!
I LOVE to learn new things, and usualy can't wait to get my hands dirty again.

Is there any future in Pascal? I meen, it sound very old, and sometimes the language can't keep up, and there is no use for it any more.

Were do you still use Pascal in the industry? Or other places for that matter...

M.

jasonf
31-05-2007, 11:50 AM
I'm no oracle ;) Is there a future in Pascal? I don't know.
I don't think it matters anyway, the IT industry changes so quickly that it won't be long before .net is seen as a legacy system and replaced by the next big thing.. I can see that Pascal will still have a place there though, along side C++.

I understand that it's quite big in the USA and is still used in the UK in places.

If you're writing games though, it doesn't matter what it's written in as long as the game is fun and it's stable. This last point is very important and a lot easier to achieve than a program written in C.

In the end, the choice to learn Pascal is yours.. I learned more about other languages by learning Pascal than by going on any training course.. it also improved my coding ability by showing me a better way to do things. It's similar enough to other languages to make the knowledge portable, which isn't something which can be said for VB. It's also very forgiving and easy to debug which isn't something which can be said for C++ (sometimes)

It certainly can't do you any harm.

Robert Kosek
31-05-2007, 11:58 AM
What people frequently underestimate is that there is a definite future for Pascal. It has been around for a long time and has both grown and changed to adapt to the ever changing face of programming ... where other languages die and spawn new variants.

Being a web designer I understand where you are coming from, especially if you know OO-PHP. ;) A neat trick with Object Oriented Pascal is that you can construct an object and then pass that object to another variable (of the same type) and it treats both as referencing the same object. No wizardry required. (Just don't forget that you passed it.)

Still use pascal in the industry? Well, lets see... web designers still use it, some game designers still use it in spite of the unjust bad rap it has received, and many companies have old pascal code they don't want to phase out yet. The latter can be modernized into a current application with ease.

There's no real question of "will pascal obsolesce?" but really the question is how bad a rap will it receive. The language is A-OK, but sometimes the headers for libraries and IDEs are the things that are flawed. In the end the question is more about perceived uselessness then about actual uselessness. (And nevermind that Pascal compiles to cleaner assembler than even C/C++ does. ;))

It's your choice, and many of us here love pascal and love making games. And all in all, I feel that pascal is the best language for simply learning to program better; even existing programmers could use a dose. If you have questions, then doubtless someone here will have an answer, but the choice is yours.

moonblade
31-05-2007, 12:09 PM
So Pascal can also be used to make web-pages?! :shock:

D*mn! This is very interesting! I think I'll try...

M.

Robert Kosek
31-05-2007, 12:46 PM
Here's a forum made entirely with Pascal (http://z505.com/cgi-bin/PasForum/index.psp), and another web-game made with Pascal (http://fern.game-server.cc/).

Pascal is more versatile than many people give it credit. ;) And working with strings in pascal is a breeze! (I hate C/C++ and their string stuff...)

WILL
31-05-2007, 02:16 PM
Hi moonblade, welcome to PGD! :)

Well it's official; 2 Jason's agree, Delphi is an IDE. :thumbup:

I don't want to restate what has been accurately said before, but just a tad more info as to how this 'Delphi language' thing came up; When Borland made the move from DOS to Windows the Delphi IDE tool was launched. This was way back when OOP was new and magical mind you. The idea to call the Object Pascal language "Delphi" came a few years & versions of it's launch. Which is what caused all the naming confusion. 2 trains of thought; 1) name the language off of the compiler and 2) name the language of a published standard.

Incidentally, noone, not even Borland has had the new revisions of the Object Pascal language standardized. So this is why you'll hear this debate almost endlessly. :?


Barring that, it's an awesome language to code it! :) With the 3 top compilers; Free Pascal, Chrome and Delphi, you can write a game for a ton of platforms; Including Win32/64/CE, Linux, MacOSX, GBA, NDS and GP2X. Even, almost, XBox360.

Probably the best place to start is getting familiar with the 'Object' part of the language. If you already know the concepts then it shouldn't take too long at all, just a few differences in the way that C-based languages do it.

So you can really start where you'd like, provided you have the main language concepts down. I'd recommend having a look through our Articles section and also the Library where we keep a pretty decent list of material there. We are going to be adding a Books section soon, that should have a fair selection if you prefer a physical book.

dmantione
31-05-2007, 05:12 PM
Pascal has a future if:
1) It has a good social network to promote it.
2) It can do things its competitors cannot do.

I'm somewhat positive about (1), since there is quite of Pascal advocacy around and sites like PGD help people doing great things in Pascal. Yet, on the other hand, languages like PHP and perhaps Ruby, have a much larger social network.

For (2), we do have some important things. For example FPC's Win64 support is big weapon fact that the open source world is going to awe on once we lauch the big PR guns. Language wise we've some cool things too. Simple things we take for granted, for example units are revolution to C programmers. The language is still evolvong. And last but not least, Pascal has got good IDEs.

moonblade
01-06-2007, 06:26 AM
Ok. Thanks for all your help guys.

I think i'll start here on PGD, and then see were it takes me.

But you haven't heard the last of me. Count on it. :wink:


M.

P.S.: Is there a big difference between the compilers and is one of them "best" and "worst"?

Robert-> very nice!! that looks very good. :shock: :D

Setharian
01-06-2007, 08:06 AM
basicly there are 2 possibilities....DCC which comes with Delphi IDE and FPC which can be used with Lazarus IDE....if you do not plan to do cross-platform development, Delphi IDE is probably the best choice otherwise FPC + Lazarus is the way....ultimately it depends on your needs...when it comes to code generation, both compilers generate very good code....

FPC: www.freepascal.org
Lazarus: www.lazarus.freepascal.org
Delphi: www.codegear.com more specificly http://www.codegear.com/downloads/free/turbo

note that Turbo Delphi (any version) is completly free, but it has 2 limitations - you cannot install IDE experts and you cannot register custom design-time components (which is the most annoying thing, that's one of the reasons why I bought Delphi 2007 for Win32)...

moonblade
01-06-2007, 08:31 AM
Ok. Thanks a million.

M.

WILL
01-06-2007, 02:11 PM
Yeah Setharian pretty much has it. But better to think of it as if you only plan on making things for Windows with Delphi. If you are running Lazarus or Mac OS X then you'll want FPC/Laz.

The other thing is that Free Pascal and the Lazarus IDE (a version of Free Pascal comes packaged with the installation, no extra setup required) are completely free and updated often. There is no paid version so it's limitless.

Another one that was not mentioned, but is very capable for making games is the .NET compiler Chrome (http://www.chromesville.com/). It's flavor of Object Pascal is almost the same, but it also has some .NET constructs that make it vary from the others a bit. It only does .NET, but recently it's been able to work with XNA, which in case you haven't heard allows you to develop for the XBox360. A juicy proposition for the budding Pascal game developer dreaming of making a game for a game console. ;)

L505
02-06-2007, 08:00 AM
Pascal has a future if:
1) It has a good social network to promote it.
2) It can do things its competitors cannot do.


3) if more developers say they use modern pascal tools and offer consulting
4) if more developers are less humble about using modern pascal and display in big bold fonts that they use modern pascal, not standard pascal

And not that this will help as much but:
5) if more developers stop Linus and Eric S Raymond from taking cheapshots like this (http://gcc.gnu.org/ml/gcc/2000-07/msg00850.html), and also notifying these people (http://kerneltrap.org/node/7434) adds publicity (bad publicity is good publicity if you handle it right) for modern pascal.
6) if someone makes a standard locked on a certain date, such as Pascal 2010 standard. I know standards can be complete BS, but it is like a patent.. people fall for them and they work.. businesses trust a language with a standard. Even if it doesn't feel right to make a standard, it is just something that should be done, even if it essentially means nothing to FPC/Delphi developers directly.