Jump to content

Recommended Posts

Hey.

 

I was interested in starting C++ Programming.

 

Firstly, Does anyone have links to tell me how to start up.

 

Does anyone know what a compiler is and what it does?

What are the file extensions with C++ ?

 

2. Is there many sites that do C++ Programming tutorials like PHP does.

 

 

THanks.

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/
Share on other sites

I hear that C is better than C++ or C#.  Since the topic is here, can I get some opinions? Naturally, there are going to be differences, but what is recommended/preferred.

 

C has been around for 35 years, since 1972. It's used in both desktop applications (i.e.: Pidgin, the popular free-and-open-source IM client) and in low-level implementations that require interaction with hardware (the Linux kernel, for example). C++ is a bit younger (since 1979), but statistics show that it's more popular than C. Keep in mind that there are noise factors, listed at the bottom of the page I linked to.

 

C# is the baby of the trio, making its first appearance in 2001. However, the platform- and OS-portability factor of the .NET project is making it a very quick up-and-comer. With the mono project implementing the .NET functionality for Unix-based systems, it's truly a programming language that everybody can use. However, C and C++ have considerable momentum behind them (I've heard it said that "they just won't die, no matter how hard we try to kill them"), so don't expect C# to become any real standard, de facto or otherwise.

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-359850
Share on other sites

*nods* I've been planning on picking up python, one more web development language (Ruby and the Rails framework), and a Generation C language.  I just couldn't figure out if I wanted the C, C++, or C#.  Naturally, learning another language gets easier and easier as you program more and more because the logics behind it are the same, you just need to learn the syntax.

 

Granted with C you have to run it through a compiler, so that is going to be a new learning experience. :)

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-360023
Share on other sites

I hear that C is better than C++ or C#.  Since the topic is here, can I get some opinions? Naturally, there are going to be differences, but what is recommended/preferred.

 

C    --> old and procedural

C++ --> OOP

C#  --> OOP the latest.

 

steelman i suggest you should pick C# for dotnet

 

or

 

JAVA

 

 

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-360029
Share on other sites

In college we started with C++ but were really only coding C procedurally.  OOP started with Java and we never really went back to C/C++.  With C/C++ you have to worry about memory, Java was nice with its garbage cleanup and seemed more intuitive to me. 

 

I would first ask yourself, why do you want to learn C/C++?  You are on a web forum asking about application programming. 

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-360044
Share on other sites

This is all a matter of opinion, but for me C is simply the best language there is all around, followed closely by C++.

 

There simply isn't any program that couldn't be written in one of those two languages.  They both provide low-level hardware interaction which makes them ideal for embedded and real-time systems as well as games.  They're both compiled so they execute fast.

 

The advantage that C provides over C++ is that it's easier to write a working C compiler than it is a C++ compiler.  So if you're working with state of the art hardware and have to write a compiler for it your job is easier.  C++ has the advantage of OOP (and a few other things) and wrapping things up behind more simple interfaces.

 

I've never programmed in Java but IMO the one thing holding it back is garbage collection.  While garbage collection certainly makes things easier on the programmer, it hurts application performance IMO.  From my experience using Java programs, they typically run great for a while but they longer they're left executing the more sluggish they become.  Garbage collection makes using Java for certain systems impossible because you can't predict when it will kick in.

 

For example:

Astronaut 1: Impact in 15 seconds.

Astronaut 2: Our automatic thrusters should handle this.

Shuttle Computer: Activating thrusters in 10

9

8

7

6

5

4

3

2

Initiating garbage collection, please wait.

Astronaut 1: O.o

Astronaut 2: -.-

 

As far as learning one of the languages goes, you're best off buying a book as it will have examples and instructions geared to your experience.  If that's not an option, you should Google search for specific programming examples as they relate to the language.

 

For example:

c++ loop tutorial

c++ function tutorial

c++ class tutorial

etc.

 

When reading the examples and you don't understand what something is, look it up in Google.

char line[256];

cin.getline(line, 256);

 

Google for 'c++ getline' to learn about it.

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-360232
Share on other sites

A)  C++ seems like the way to go simply because of the OOP.  I'm trying to pick up OOP in PHP and the concept is so hard because I've always programmed procedural in PHP. So, perhaps if I start off the OOP way in C, I will be better off.

 

B) Some libraries have very few books, and fewer programming books. I'm from a small town and we had a find jobs online book and an HTML for Dummies book last I checked. WoW! What a major help. On the aff. side, there is a new system called interlibrary loan which almost all libraries have.  You can loan/check out books from other libraries, the only thing is is it is normally a dollar and you have to wait for it to get mailed to the library using US postal.

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-360317
Share on other sites

Also:

 

http://www.cplusplus.com/doc/tutorial/

http://www.cprogramming.com/tutorial.html

http://www.glenmccl.com/tutor.htm

http://www.google.com/search?source=ig&hl=en&q=C%2B%2B+tutorials&btnG=Google+Search

 

 

I know some people have a hard time trying to figure out how google works, so I'm just going to do now what I normally end up doing in the long run. :-D

Link to comment
https://forums.phpfreaks.com/topic/71438-c-programming/#findComment-360318
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.