|
View Poll Results: Which programming language to learn | |||
Learn C++ First | 2 | 22.22% | |
Learn Java First | 4 | 44.44% | |
Need to know both | 1 | 11.11% | |
Doesn't matter - programming is programming | 2 | 22.22% | |
Voters: 9. You may not vote on this poll |
|
Thread Tools |
#1
|
|||
|
|||
Which programming language to learn
Java? C++? Eclipse or some other IDE? Any recommendations? I'm looking at Java code and C++ code and it all looks the same to me. I did a search on the internet and apparently, they are the same! So, which would you programmers suggest to learn first, C++ or Java? Or maybe something else? Or does it really matter,
H |
#2
|
|||
|
|||
Superficially, they look the same, but they are different and they have their plusses and minuses in different situations. It depends on what kind of coding you want to do.
|
#3
|
|||
|
|||
Quote:
I guess my question is, if you fluently know Java, does that make you pretty fluent in C++? How important is the IDE that you are dealing with and the type of errors you are grappling with? From personal experience, it comes down to errors you are grappling with the IDE, be it Codeblocks or Eclipse rather than the language itself, H |
#4
|
|||
|
|||
As an analogy, this is a bit like asking if you should start with piano or violin. Do you have some experience programming already? What's your starting point, and what's your goal?
Is this your first language? My impression is not. If so, I would say neither - try Python instead. Java and C++ are both object-oriented, use curly braces, and have similar control structures, but there are some pretty fundamental differences. Java has some idiosyncrasies, and is somewhat verbose, but it's fairly straightforward. C++ is much closer to the machine, and requires you to think about storage management. Java is a lot closer to Javascript, Scala, Python, Ruby, the new Swift language from Apple, etc. The IDE can help, but you really need to understand the underlying model of the language. I'd avoid a fancy IDE (or avoid its hand-holding features) when you're starting out. |
#5
|
|||
|
|||
These are excellent questions. Unless you have a need for maximum performance, I suggest staying away from C++. It provides, in the words of Allen Holub, "enough rope to shoot yourself in the foot." It's very powerful, but can be trickier than other languages (like Java, C#, Python, Swift, et al) to reliably do simpler things like database access and web site back ends. Yes Java looks much like C/C++ but they really are quite different when you're writing a full application.
|
#6
|
|||
|
|||
No. C# looks a lot like Java too, but as the size of your functions/modules/applications grows there's enough language/environment specific stuff that requires time to learn. For example, I've been working on the .NET platform since it was introduced in early 2002. If I had to produce full applications in Java two things would happen: 1) I would take significantly longer during while on the wrong side of the learning curve, and 2) my Java programs would look very C#-ish. So even though they're both semicolon-terminated OO languages with many of the same control structures, they're quite different at scale.
|
#7
|
|||
|
|||
Thank you for all responses, here's the crux of my problem.
Currently, I'm working in a proprietary language where everything is global. I look up my data definitions in a massive Bible (categorized of course) to find data elements, structures, underlying attributes, data types, a sort of one stop shopping to get the nuts and bolts of the data structures involved. With C++ or Java, it seems like everything is embedded in #include or macros that aren't inherently obvious. An on demand structure of the data types being programmed would be nice in Java or C++. I guess the programming background that I come from is so foreign to me, I'm trying to grasp my mind around how these standard languages are a benefit to other proprietary models out there. H Thanks again for all your input, you are talking to someone that has been working in a proprietary type setting for about 25 years that is trying to grasp where the standard ideal language model(s) have come thus far. |
#8
|
|||
|
|||
decide what industry you want to work in first. What do you want to make? some industries won't use either of those two because of software assurance issues.
|
#9
|
|||
|
|||
Quote:
Rarely, do you see books that generically try to describe the model of a language with complete real world examples. I guess C++ and Java do come close with some publications, but those rarely, if ever have actually included CD's with real working programs, H |
#10
|
|||
|
|||
Quote:
H |
#11
|
|||
|
|||
Quote:
Or you could approach it using functional programming (Common Lisp, Haskell, Clojure, F#, and many others)... FP is not nearly as widespread as OO, but can be better suited for solving some problems like concurrency. |
#12
|
|||
|
|||
Quote:
There is memory, and there are CPU registers. Memory (RAM) is just a huge array of bytes, usually billions these days. A memory address is just a number... an index into that array. CPU registers are a sort of memory too, but internal to the CPU, and there are just a few of them. Usually 32 or 64 bits each, and they are referred to by name rather than having addresses. The CPU performs operations on registers, such as adding the value of one to the value of another, or writing the value out to memory, or loading a value from memory into a register. When performing memory operations, you need a second register which contains the memory address that you're writing/reading from. There's also a special register called the program counter, which contains the memory address of the next instruction for the CPU to execute. The program is just more ones and zeroes out in memory somewhere, which the CPU interprets to mean different operations. In C++, pointer variables are internally no different from integers. A pointer stores a memory address. Doesn't matter what type of thing it points to, a pointer is always just a number. Either 32 or 64 bits depending on whether you're compiling for 64-bit Windows or not (32-bit pointers can only reach 4GB of unique memory addresses). The pointer type only comes into play when you dereference the pointer. Then the compiler will output appropriate instructions, for example to load an 8 bit value or 32 bit value from memory into a register, perform some operations on it, maybe write it back to memory, or whatever else the C++ code says to do with the variable pointed to. Function calls basically boil down to saving the current program counter to memory (push it onto the stack) and then set the program counter to the memory address of the function. The CPU continues executing from there, and at the end of the function will be an instruction to read the saved program counter value back from memory (pop it off of the stack). Thus the CPU continues executing from the location that the function was called from. |
#13
|
|||
|
|||
Another option is to get a certification in HL7, Version 2.x or 3.x. It's a health care messaging standard. Lots of work out there in messaging. I'm sure you're aware of it since you're in the health care industry.
|
#14
|
|||
|
|||
Quote:
If you are going to stay in health care, then Java certainly makes more sense. To learn the language, you could just start with the official online tutorial. Another choice might be the front part of the latest edition of Java in a Nutshell. I used an earlier edition of this in the past when I first learned Java. It was very succinct but easy to get through. You might consider various online video courses as overviews. I have a friend who likes the Deitel and Deitel books, though I find them very dry (but I was just trying to look something up). Once you get past the language, Java is all about the vast set of libraries available, both built-in and add-on, like the various Apache libraries, Spring or Java EE stuff, etc. Depending on where you walk, some high-level decision has often been made to use some framework, which will very much affect how you write code. Java 8 added a number of features (lambdas, streams (not the I/O kind), etc.) that make doing functional-style and implicitly concurrent programming much easier. I am currently reading and enjoying Java SE 8 for the Really Impatient, which is a very concise and clear intro to the new features. If your proprietary system used its own non-relational database model, then you might also need to catch up on SQL and relational databases, and also check out the latest "NoSQL" trends and fads. Don't get hung up on the IDE's yet. They are just the power tools. Choice is a matter of personal taste. Eclipse is the most common, but people also like IntelliJ (there's a free version). I like NetBeans, which I find to be somewhat more lightweight. |
#15
|
|||
|
|||
Yep, it's a Mumps derivative. The language used to implement the system is actually an FP. They (the vendor) did start development where they had their own OS and language they both hosted. Course, that was in the mainframe years BM (before Microsoft). Nowadays though, you're either using MS to host your stuff or your pretty much out of business (sure there still are the few Unix shops around). It's rather ironic, their (Health Care Vendor) microkernel OS is ten fold more stable than MS, and now they've got to take the system down for bug fixes and security patches monthly, whereas before, when they were hosting their own OS, they were taking the system down maybe once a year.
Anyway, I agree, concentrate on the language and not the IDE, but that's tough to do sometime when the IDE is pretty much required (under MS at least) to get some source code written, H |