10 ms·
Java is tremendously influenced by C and C++. Any experienced C++ programmer can learn Java easily because it has a similar syntax but a much simpler palette of
by nayuki 8y ago
Java is tremendously influenced by C and C++. Any experienced C++ programmer can learn Java easily because it has a similar syntax but a much simpler palette of language constructs.
I am glad that Java didn't copy these aspects of C and C++: https://www.nayuki.io/page/undefined-behavior-in-c-and-cplusplus-programs https://www.nayuki.io/page/undefined-behavior-in-c-and-cplus... ; https://www.nayuki.io/page/near-duplicate-features-of-cplusplus https://www.nayuki.io/page/near-duplicate-features-of-cplusp...
- astrange 8y agoUndefined behavior is very useful, and Java doesn't replace it with anything better for high-performance CPU programming. In particular, C loops can only be optimized because signed loop counters are assumed not to overflow. Java also doesn't have SIMD, and a very weak form of arrays as value types leads to pointer chasing.
- pjmlp 8y agoAnd Objective-C, stuff like interfaces, resource bundles, lightweight metaclasses, APIs for distributed computing (J2EE was based on an internal OpenSTEP framework).