r/java • • Jan 18 '22

What are some very less known facts about java?

I've got assignment from college to find out rare facts or fun facts about java, so little help will be appreciated :)

Edit: Thanks for all these suggestions guys. It's going to help me alot and also Almost all of these facts i didn't knew till now. Thanks :) <3

179 Upvotes

297 comments sorted by

View all comments

Show parent comments

4

u/[deleted] Jan 18 '22

I'm afraid that one's out of date. Now they use an indy-instruction and can use a variety of approaches to more efficiently produce the concatenated string. You should still avoid String concatenation in a loop though (for the same reasons as before).

Yes you are right. from java 9. I'm afraid most are still using java <= 8

1

u/8igg7e5 Jan 19 '22

Based on surveys the majority of organisations are using both versions newer than or equal to or less than Java 8.

Yes there are a lot of developers still maintaining projects in older Java editions, but the uptake of newer releases is much higher than seems to be commonly understood.