C and C++ are very similar, but C++ is undoubtedly the better language because it offers OO which makes programming a lot more organized and sufficient.
You are comparing apples to oranges here. Maybe 10+ years ago when these two languages were competing in the same field this was the case - not any more. I've coded both since I was a kid and I still do. I use C like I would have used Assembly when I was a kid - to code low level sockets and speed intensive libraries (most DLL's in windows are coded in C). Up until a year ago, I was coding massive amounts of C++ for windows based apps... until I moved over to C#. Also, if OO is truly the holy grail of languages and thats the factor that makes it 'better'. Why aren't we all using Eiffel or Smalltalk? instead... PHP, Java and C# command massive followings despite the fact that people continue to code quite a bit of procedural code - just mashed together to make it look OO.
Once again, asking what language is 'better' is silly. What are you trying to accomplish? tell me that and I will tell you what language is better suited. This question is akin to asking "what is the best tool?"... would you use a table saw to drill a hole? C would be the easier, it's a very basic language. Almost all of it's functionality comes from external libraries, the core is as basic as it gets.
in my opinion C++ is better than C in the system of output and input and in C++ you can use C without synthax error
Correct me if I'm wrong but C++ is an extension of C, so pretty much any valid C source will compile and run on a C++ compiler, that's why I said C++ is better. =/ Not to mention it has bigger library collection, stronger typing, blablabla. There's just whole lot advantage in C++ man. But really, that's just my opinion, I'm not trying to pick a fight here..
As there is lot of features present in C++ like abstraction encapsulation inheritence polymorphism dynamic binding These all are easy to understand and to use. Even our data that is very critical, is also very safe in C++ over C as data members are bound in a class and only function that are member of the class can access only. To learn about C++, got through below link. http://www.boundscheck.com/category/knowledge-base/cpp/ regards harris
For placement purpose better learn C++ ... C involves pure logic. There is a little to learn from programming perspective in C , but a lot from problem solving perspective. But in C++ you can always tell few of the basic concepts like polymorphism , encapsulation , inheritance etc which will help you clear placement interview. It'll take roughly 3-4 days to brush up these concepts. But you will not become a programmer in 3-4 days
Since I agree with Linus Torvalds, I'll just quote him: He also says anything you can do in C++, you can do it in C. True.
I believe, though C++ is the extension of C, C++ is better, with its advantage in Object Oriented Programming
C++ is better because this is object oriented language and C is procedural language.but basic is same(logic).
This topic should be closed. The replies are becoming increasingly more inane, just for the sake of upping ones post count. Ugh.
I would recommend you to read about OOP concepts. If your project needs them, then go for C++. Otherwise if you just want a small program, then C is enough. However the kind of program - domain also plays a significant role on the language you choose in general. Also might be very project specific requirements which might be done only in certain set of languages. Always understand what you want, and then choose your language. If you do it in the other way, you may have to spend too much time in solving problems that are already being solved or primitives of some other programming language. I know my answer is not specific to C/C++, but take it as a guideline for any language.