Thread: About learning C ++ (jjust the concepts)

  1. #1
    Registered User
    Join Date
    Dec 2012
    Posts
    19

    About learning C ++ (jjust the concepts)

    Hello ,
    I am pretty comfortable with C programming.
    I wanna start learning Java now, but the problem is that i wanna know about OOP(object oriented programming) which i can learn in C++ but i dun wanna learn c++ as it will take a lot of time and i am not even gonna use c++ anyway.
    So is there any resource like video , book or aritcles or nything that can help me just to get familiarized with the OOP principles and all the meaning of words like :
    Instances
    Objects
    Class
    etc

    Thankyou

    PS: I am joining a class for learning JAVA where they will assume that i know C programming , C++ basics and OOP

  2. #2
    spaghetticode
    Guest
    There are as many books on OOP as stars in the sky. I'm not sure why you want to learn the concepts via C++ if you are not planning to use C++. Why not learning it via Java directly? You might want to check out O'Reillys Head First series, they have a great book on Java which goes a lot into detail concerning the concepts of OOP. Since you already do have experience in C, you might as well buy a language independent book just on the principles of OOP.

    EDIT: Since your course on Java will require some C++ basics, the tutorial on this very website might be sufficient.
    Last edited by spaghetticode; 04-17-2013 at 06:27 AM. Reason: Addition

  3. #3
    Registered User
    Join Date
    Dec 2012
    Posts
    19
    Quote Originally Posted by dennis.cpp View Post
    There are as many books on OOP as stars in the sky. I'm not sure why you want to learn the concepts via C++ if you are not planning to use C++. Why not learning it via Java directly? You might want to check out O'Reillys Head First series, they have a great book on Java which goes a lot into detail concerning the concepts of OOP. Since you already do have experience in C, you might as well buy a language independent book just on the principles of OOP.

    EDIT: Since your course on Java will require some C++ basics, the tutorial on this very website might be sufficient.
    i just bought the book of alex "Jumping into C++" its like 400 pages i can read through it right? and may be even learn c++ , my java class is still 15 days later ..
    "Jumping into C++" Wud be sufficient??

  4. #4
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Learn the language you want to learn. If you are going to learn Java, then don't bother reading a C++ book.
    OOP is a paradigm, but the way of using this paradigm is different in different languages.
    Therefore, you are better off learning the paradigms and how they are used in the language you intend to learn.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  5. #5
    Registered User
    Join Date
    May 2010
    Posts
    4,633
    Since you state you already can program in C, I agree with Elysia, if your going to learn Java learn Java. C++ and Java don't do OOP the same so you would probably be better off not knowing C++. I'd just try to get the course text and start reading and playing early.


    Jim

  6. #6
    Registered User
    Join Date
    Jun 2012
    Location
    Morden, UK
    Posts
    128
    Quote Originally Posted by Elysia View Post
    Learn the language you want to learn. If you are going to learn Java, then don't bother reading a C++ book.
    OOP is a paradigm, but the way of using this paradigm is different in different languages.
    Therefore, you are better off learning the paradigms and how they are used in the language you intend to learn.
    This was interesting to me. I'm learning C++ because I want to learn it, not because I think I will use it particularly for work. This may seem insane but I think it will offer a really solid foundation for learning other languages, kind of like learning Latin before Italian/French/Spanish.

    Maybe I'm wrong but I'm much more likely to be using python/ruby/php as I'm into web development. My java course starts October 2012 too.

    So why aren't I learning them first? Well I have to start somewhere right, and I still feel that C++ will not get me into any bad habits before trying the other language. I feel that if I can get going at C++, then anything else will be a little easier (not easy, but easier). It's a very important language in my opinion that makes many things I do on computers/consoles possible. Why would I NOT want a piece of that! I want to learn how to program, so choosing a syntax that I like the best is not top of my priorities.

    I plan to learn as much as possible in a variety of languages anyway as I have a very keen interest. I'm currently reading a book about logic gates to assembly language and how the very base stuff works.

    With this in mind, I don't think any starting place would be wrong in my situation as I am not 100% what I want to do in the future. What I don't want is to go ahead and learn something like python, and then find I need C++ in the future! I'd rather do it the other way round. Plus, I really enjoy C++ so live and let live!

    I have no wish to hijack this thread but I'd like to share my thoughts with you.

  7. #7
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Learning several languages is certainly important. If such is the case, then it is debatable which language is best to learn first.
    In any case, when aiming to learn only a specific language, then not learning another language as a base is usually better.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  8. #8
    Lurking whiteflags's Avatar
    Join Date
    Apr 2006
    Location
    United States
    Posts
    9,613
    Well, learning Java was not hard for me. I learned C++ first, but it isn't like C++ helped me avoid bad habits, either. I will elucidate just how unhelpful C++ is:

    Java is garbage collected, so I threw away all of C++'s memory management practices out the window, because I won't be using them.

    Experience with exceptions demystified a lot, but is again different.

    Java has an import system for modules: C++ does not.

    In regards to inheritance, OOP theory is more important than C++'s implementation of it if you're having problems understanding how Java does it.

    In regards to encapsulation, Java is different enough to be annoying. You will have to relearn what certain keywords mean in Java.

    What I found helpful was the experience I had with general OOP concepts, like encapsulation, inheritance, and polymorphism by learning C++ first, that helped me quickly pick up Java. I still had to learn Java's spin on OOP concepts, but I didn't need to have explained what inheritance is, nor polymorphism, nor encapsulation. So that freed up a lot of time for just understanding what Java does do. I do not think it is worth anyone's time to learn C++ just to learn Java. For if Java clicks with you, you should learn about encapsulation, inheritance and polymorphism. You will understand why these things are important to the language. (In particular I like the way the Deitel Java book is written for learning OOP the first time.) And then when you understand why they're important, you don't really need to relearn that bit. So when you pick up your next object oriented language, you'll be that much smarter.

    That's it. Canonical code, things like that, it's really a crapshoot what applies and what doesn't. If you have a learning shortcut from experience, take it, but don't count on there being one.
    Last edited by whiteflags; 04-17-2013 at 11:52 PM.

  9. #9
    spaghetticode
    Guest
    Quote Originally Posted by whiteflags View Post
    I do not think it is worth anyone's time to learn C++ just to learn Java.
    This is what basically I was trying to say too. If the OP is personally interested in C++ regardless of his Java class and his actual day-to-day usage, like samwillc, there's nothing wrong with learning it. With the OP's claimed experience in C the tutorial of this community should do. But just wanting to learn C++ as a preparation for a Java class is nonsense.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Concepts of memory
    By Lesshardtofind in forum C++ Programming
    Replies: 39
    Last Post: 12-11-2012, 01:36 AM
  2. array concepts need
    By Shinzu911 in forum C Programming
    Replies: 3
    Last Post: 05-04-2012, 11:27 PM
  3. Some basic C++ concepts
    By tx1988 in forum C++ Programming
    Replies: 12
    Last Post: 09-15-2007, 08:16 PM
  4. Programming concepts
    By lyx in forum C++ Programming
    Replies: 2
    Last Post: 12-03-2003, 12:37 AM