AMD
3.1 of 5 1,049 reviews
www.amd.com Sunnyvale, CA 5000+ Employees

AMD Co-Op Engineer Interview Question

I interviewed in Sunnyvale, CA and was asked:
"Main difference between C++ and Java?"
Tags: java, c++
Add Tags [?]
Answer Flag Question

Part of a Co-Op Engineer Interview Review - one of 239 AMD Interview Reviews

Answers & Comments

0
of 0
votes
1/ I would say that the most important difference is portability. A Java program only needs to be written once but can run on any OS that runs the Java virtual machine. A C++ program on the other hand is tied to the OS it was written for (in most cases it is windows).
2/ The second big difference is the memory management process. In Java it is done automatically by a process called the garbage collector (gc) whereas in C++ it has to be hardcoded by the developer and as a result is prone to errors (though it gives more control to the developer).
3/ Java is slightly slower than C++ as a result of running on a virtual machine (it is said to be an interpreted language).
4/ Java is single inheritance (but can implement multiple interfaces) whereas C++ is multiple inheritance.
5/ Java is cool, C++ sucks
- jule64 on Sep 28, 2012 Flag Response

To comment on this question, Sign In with Facebook or Sign Up


Tags are like keywords that help categorize interview questions that have something in common.

Glassdoor is your free inside look at AMD interview questions and advice. All interview reviews posted anonymously by AMD employees and interview candidates.