0
What is the difference between Java and C++, with syntax and which 1 would you choose and why?
For the sake of clarity and time management
2 Respostas
+ 1
the only Big difference to me would be the file layout and tge import/include statements.
what I mean by file layout is that in cpp you have a namespace ans then int main. where as in java you have a package and public class x with public static void main.
other than that the majority of the syntax is Very similar.
in classes you have to tell it if it is public or private instead of just saying private: like in cpp.
and there are some different keywords like final and const.
if you want to know how everything is supposed to work. "bit by bit" I would use cpp because you use pointers and reference values. it helps give you a sense of what the computer has to do with that information.
if you want a more "user friendly" oopl I would use java. they have Much more built in functionalities and java is used in alot more. like mobile and web development. where as cpp is used for like embedded systems and image processing.
it all depends on what ide you want to use I guess haha
hope this helps!!
+ 1
very helpful explanation.
I take your advice and thank you very much