Is there anything wrong with just using plain old C?

Started by
32 comments, last by tad pole 20 years ago
Is there anything wrong with just learning all the funcionality of the C programming language as opposed to learning oo programming? The univeristy that I go to doesnt offer C++ programming classes. They structure their courses around java but also offer C programming classes. I am not a Comp Sci major but I do want to take a few programming classes just for fun. Will you eventually run into limitations just using C for OpenGL and game programming as opposed to using an object oriented language? Thanks
Advertisement
C can do anything C++ can do. It just might take longer, and be a tad more error prone. The original C++ compilers output C code. :D
Well, everything is moving towards OOP. C isn''t safe, and takes longer to make medium to large sized projects.
And the rockets' red glare, the bombs bursting in air,gave proof through the fight that our flag was still there.Oh say, does that star-spangled banner yet waveover the land of the free and the home of the brave?
Is there anything wrong with just using plain old C?

No.

Is there anything wrong with just learning all the funcionality of the C programming language as opposed to learning oo programming?

If you want to get a job, you'll need to have whatever skills recruiters want. (ok, you're not a CS major, but still).

Will you eventually run into limitations just using C for OpenGL and game programming as opposed to using an object oriented language?

Not really. However, as you add to it, your code may evolve object-oriented features, at which point using a language that natively support them is preferable to doing it all by hand. Once your game entities start growing type codes, and your functions get peppered with type switch tables, you'll soon yearn for compiler-managed RTTI

The more you know, the more options you have and the more chances you'll find the right tool, be it procedural, logic, functional, object-oriented, generic programming or something else.

Anyway, learn python, okay ?

“Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.” — Brian W. Kernighan

[edited by - Fruny on April 21, 2004 8:03:50 PM]
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." — Brian W. Kernighan
My advice would be to learn Java, that way you get OOP experience and it is very easy to migrate to C++ using online tutorials, books, etc.

Edit: or learn Python like Fruny suggests, but with Java you can do that course at uni.

[edited by - henrym on April 21, 2004 8:05:36 PM]
Well I am not very interested in learning Python and I kinda wanna stick to C becuase that is what the univeristy offers. I could take a java class but they also require you to take seperate labs that go along with them. I dont wanna get involved in all that to tell you the truth because that is not my major and I dont want that to take center stage in front of courses for my major. The java classes are also restricted courses so I am not even sure if they would let me in without being a CS major or minor.

I made the mistake of taking all my gen ed courses before picking a major so know I am stuck taking all the hard courses with no gen eds to break up my day and make it a little easier. That is one reason I dont wanna take java and then have to sign up for the lab that goes with it. If they would even let me in that is.

oh and I should add that after next week I will be done with a CS class. It is good old QBasic! :/

If you come to the school and cant write a program with certain specs in any language they make you take qbasic to make you familiar with certain programming concepts. I think I have an A in the class so far so I am not totally unfamiliar with all programming concepts.

You asked, and we answered.
And the rockets' red glare, the bombs bursting in air,gave proof through the fight that our flag was still there.Oh say, does that star-spangled banner yet waveover the land of the free and the home of the brave?
With C, it will be a lot harder making more advanced programs.
And the rockets' red glare, the bombs bursting in air,gave proof through the fight that our flag was still there.Oh say, does that star-spangled banner yet waveover the land of the free and the home of the brave?
If C is all they offer as ''casual'' programming courses, well, sure, why not. I need to caution you though that it''s not the friendliest of languages and that some of its idioms can be hard to shake off later (just look at how many people stick with char* in spite of the headaches it gives them). As you go, keep your mind open to other ways of doing things.

And IMHO, given that you''ve already successfully been through a programming class, you ought to be able to pick up Python by yourself with very little trouble (it even has OpenGL bindings )

“Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.” — Brian W. Kernighan
"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." — Brian W. Kernighan

This topic is closed to new replies.

Advertisement