DEV Community

Discussion on: Syntax Differences: JavaScript vs. Java

Collapse
 
bias profile image
Tobias Nickel

Sometimes I wonder how much java and js code could be written intechangably. now that Java has the var keyword and arrow functions.

Collapse
 
colerau profile image
Cole Rau

I didn't know Java has those features now!

Collapse
 
thorstenhirsch profile image
Thorsten Hirsch

Not much, actually. While the syntax is rather similar the language design is very different and the runtimes are even more different.

Java is much more similar to C# in their goals and language design, so they might be what comes close to "interchangeable".