-
Want to learn C (or C++ or Pro*C) - any tips?
I am looking into learning (self-teach) C or C++ (or even Pro*C) but don't know where to start. I'm a complete newcomer to this - the only vaguely related experience I have is VBA and SQL.
To start with, what is the difference between C, C++ and Pro*C? I would prefer a high level explanation since I am not familiar with any of the terminology. Which of the three is most commonly used and which is the best (if different to the most common one)?
Now, how do I go about learning to any of those languages? Which tools would I need (Visual Studio??) to start with?
Any help would be greatly appreciated. Please note, I am not familiar with the terminology (hence I got stuck when browsing the net for help - printf and scanf, etc).
Thanks
| AMD64 3000+ (skt 754)| 256MB Sapphire Radeon 9600XT | MSI K8N Neo Platinum | 450W Antec SP-450PGB PSU |Corsair 1024MB CMX1024-3200C2PT + TwinMOS PC3200 512MB CL2.5 | 80GB WD SE HDD (8MB Cache) | 180GB IBM/Hitachi 180GXP HDD | NEC 2500A DVR+-RW | Creative FPS1000 Speakers |
-
NullPointerException
Teach Yourself C in 24 hours
Actually, a google of "teach yourself c" will lead to a bunch of C and C++ sites with some good intro material. Of course, the real books show up too.
C is the core language. It's been around since the 80s and is probably the most ubiquitous language. In the C language, the "++" terminology means increment by one, and so "C++" is supposed to be one better than C. Nerd humor at work there. C++ is different because it is object-oriented (classes, methods) instead of procedural (top-down with subroutines). Pro*C is special in that it's tied to SQL, so SQL statements are compiled with some outside library and then the rest of the C/C++ code is compiled normally.
If you're writing on Windows in C++, Visual Studio is the tool to start with (but it isn't free). If you're into learning the language and not an IDE, start with DevC or even just gcc and a text editor.
Open Source is free like a puppy is free.
It's only when you look at an ant through a magnifying glass on a sunny day that you realise how often they burst into flames.
Understanding Evolution
-
Catfish
Um, C has been around officially since 1974, when the Unix operating system was announced by Bell Labs and AT&T. Unofficially, it was created in 1971 and '72 and Unix was re-written in C in 1972. (Before that, Unix was written in an interpeted language called B. It was REALLY SLOW. )
-
NullPointerException
True, C started in the 70s, but it really didn't take off until after K&R's book was published in '78. And wasn't standardized by ANSI until sometime in the mid '80s.
Open Source is free like a puppy is free.
It's only when you look at an ant through a magnifying glass on a sunny day that you realise how often they burst into flames.
Understanding Evolution
-
Thanks for the link rock. Searching google finds all sorts of useless links......and many useful ones which have some good aspects. the link you gave however seems to cover the very basics I was after. I will have a look through when I get a chance.
So, if C has been around for so long how comes it's survived? Is it that powerful?
Also, which is better C or C++? I assume there is no such thing as just C+
Thanks
| AMD64 3000+ (skt 754)| 256MB Sapphire Radeon 9600XT | MSI K8N Neo Platinum | 450W Antec SP-450PGB PSU |Corsair 1024MB CMX1024-3200C2PT + TwinMOS PC3200 512MB CL2.5 | 80GB WD SE HDD (8MB Cache) | 180GB IBM/Hitachi 180GXP HDD | NEC 2500A DVR+-RW | Creative FPS1000 Speakers |
-
Goldfish
C and C++ have been around so long because their low level capabilities and speed make them such awesome multi-purpose languages.
I'd recommend learning C++. A well written C++ book or tutorial set will start you with procedural C style stuff and you'll get into object oriented stuff later. At least that's how I liked learning it. When you learn one, you basically learn the other, they are so similar. C++ is probably the way to go for two reasons. One, it's a superset of C, it's got everything C has and more. Any C program can usually be easily converted to C++, it's usually just small syntax or fuction names that change, and some stuff that newer compilers demand. Object oriented programming is just overall a better, safer, easier way to do things, at least in the eyes of many. Hell, you learn one object oriented language, you learn them all they say. C, C++ and Java are quite similar (with Java being very class heavy). PHP and Perl are easy to pickup after learning C or C++, too.
-
NullPointerException
I'd have to agree. Unless in the long run you're definitely going to be doing procedural programming (e.g., Fortran or 4GL languages like Matlab or PV-WAVE), C++ will be the place to start. From C++ it's much easier to move to Java and C#, too.
Open Source is free like a puppy is free.
It's only when you look at an ant through a magnifying glass on a sunny day that you realise how often they burst into flames.
Understanding Evolution
-
-
C# is the illegitimate son of Java and C. Basicly C# is an object-oriented language while C is procedural. C# also has a lot more built in libraries that C does and is used more in the real world for business solutions than C. I began by learning C++ and once you know C++, C# is easy, C is annoying cuz C++ does just as much, and you really don't need to know anything about the others.
C+ does not exist
to increment a variable by 1 in C++ you type
myVar++; // this increments myVar by one so 1 now is 2
so C++ is meant to be C + 1
Last edited by TheSpegmaster; 05-26-2004 at 09:54 AM.
Pentium 4 2.8GHz w/ 1MB L2 cache
ASUS P4P800-E Deluxe
1024MB PC3200 DDR RAM (Dual Channel)
ATI Radeon 9800 Pro w/ 128MB DDR
8x NEC DVD-RW
16x Samsung DVD-ROM
120GB Samsung 7200 RPM SATA
120GB Western Digital 7200 RPM
Asound 4 Ports Nway Switch
Netgear WG111 54 Mbps Wireless USB 2.0 Adapter
3dMark2001 SE: 16183 Marks
3dMark2003 : 5798 Marks
-
Catfish
C is not powerful. It is elegant, simple and fast, which is why it's been around for so long. It's an ideal system (low level) programming language.
C++ is more of a higher level language. It's far more bloated but has many features that make it attractive for large projects with large teams. It's also a more recent invention so it has many modern features, so it would be a great place to start.
I didn't notice anyone mention tools yet. MS has released the command line tools for Visual C++ for free:
http://msdn.microsoft.com/visualc/vctoolkit2003/
I like the MinGW compiler instead, which is a native port of the GNU compiler:
http://www.mingw.org
MinGW also has other GNU tools in their Msys package, which I like as well.
Finally, IDE editors are evil. Use gvim. http://www.vim.org
-
NullPointerException
FYI, the SDK for the .NET framework is a free download on MSDN too. So you can compile any of the .NET languages (C#, VB.NET and C++.NET) from the command line. Of course, it's a lot easier with Visual Studio.NET.
linkage
Open Source is free like a puppy is free.
It's only when you look at an ant through a magnifying glass on a sunny day that you realise how often they burst into flames.
Understanding Evolution
-
Hammerhead Shark
C++ is my language of choice. Self taught it to myself as a freshman in highschool 4 years ago, and have been pleased with it since. It is much more capable than C, hence the step up (++). I learned from SAMS Teach Yourself C++ in 21 Days--it did a good job of explaining everything in easy to understand terminology, and didn't get me lost in details. From there, stick around on forums like this if you have questions, there are always people here to help.
Audio Setups:
E-MU 0404 ---toslink---> Panasonic SA-XR55s ---> Ascend Acoustics CBM170's with Dayton 12"
E-MU 0404 ---analog---> Little Dot II tube amp ---> Beyerdynamics DT880 or Sennheiser HD280 pros.
Technics SL-1200 MKII ---> TCC TC-750LC Phono Preamp ---> Panasonic SA-XR55s ---> Ascend Acoustics CBM170's with Dayton 12"
Proud Sharky Folding@Home member! (Rank 37 and counting...)
-
| AMD64 3000+ (skt 754)| 256MB Sapphire Radeon 9600XT | MSI K8N Neo Platinum | 450W Antec SP-450PGB PSU |Corsair 1024MB CMX1024-3200C2PT + TwinMOS PC3200 512MB CL2.5 | 80GB WD SE HDD (8MB Cache) | 180GB IBM/Hitachi 180GXP HDD | NEC 2500A DVR+-RW | Creative FPS1000 Speakers |
-
NullPointerException
Instead of trying to figure out Visual Studio, you might want to start with something simpler like Dev-C++. With their docs and your sample code you should be able to get going.
Open Source is free like a puppy is free.
It's only when you look at an ant through a magnifying glass on a sunny day that you realise how often they burst into flames.
Understanding Evolution
-
Thanks rock. Downloading Dev C++ 5 as I type. Also found this site:
Teach Yourself Visual C++ 6 in 21 Days
| AMD64 3000+ (skt 754)| 256MB Sapphire Radeon 9600XT | MSI K8N Neo Platinum | 450W Antec SP-450PGB PSU |Corsair 1024MB CMX1024-3200C2PT + TwinMOS PC3200 512MB CL2.5 | 80GB WD SE HDD (8MB Cache) | 180GB IBM/Hitachi 180GXP HDD | NEC 2500A DVR+-RW | Creative FPS1000 Speakers |
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|