• Java Programming
  • JavaScript
  • The Difference Between

What are the differences between java and JavaScript?

Top Answer
User Avatar
Wiki User
Answered 2011-09-12 06:59:52

There's a world of difference between the two. Javascript is used for front-end web development while Java can only be used as a back-end language within a web environment. Java doesn't need a web browser to compile and execute like Javascript does. Java is compiled prior to runtime while Javascript is compiled at runtime. The syntax/reserved-words are also different. There's many more differences if you go and do some research on the two languages.

Following are some points which differentiates java & javascript

  1. Java follows strong type checking where as Javascript is very flexible in datatype(loosly typed). Supports types which represents boolean,int,string
    • Ex : Variables in Java is declared as datatype ; --> int num;

    • But in Javascript variable declaration will be as var ; --> var myName;

  2. Javascript support function declarations, but without accessibility specifiers,parameter datatype,return type
  • Javascript : function fcnName(str)

........function body..........

  • Java : public int functionName(int no)

..........function body.........

will continue with answer...........
Java is a programming language designed to run in a Java Virtual Machine which is itself a program that allows java programs to run on any computer/device a Java Virtual Machine has been programmed for.

Java script is a scripting language that runs inside of a internet browser to enhance the web experience. Java script is designed to expand the capabilities of a web page so that it behaves more like a program on the computer than just a static page of text and images.

User Avatar

Your Answer


Still have questions?

Related Questions

What do you call java and javascript?

Well you get java as java and javascript as iava.

What is the difference between javascript and java programming langugage?

JavaScript and java are 2 completely different things. JavaScript is in web pages to make it more interesting and java is a complex computing language devised from c + c++.

What is the difference between javascript and java language?

JavaScript and Java are two different programming languages. Java is a server-side, statically typed language. JavaScript is a mostly client-side, dynamically typed language. Java supports heavy back end computations while JavaScript enables interactive AJAX ones.

Difference between Java and JavaScript?

JavaScript is a completely different language than Java. They have some, but few, similarities in syntax, and are used in completely different domains.

What is differences between JavaScript and livescript?

JavaScript is LiveScript. It was renamed to gain popularity. The JavaScript name was rejected by then Sun Microsystems who owned the Java trademark. Now the official name is ECMAScript, while it is still commonly referred to as JavaScript. In Internet Explorer it is called JScript. Different names, same language.

How java script is advance of java?

Usage of JavaScript is different from Java. Though both of them are interpreted language, Javascript is used as script language for client side programming in websites. There isn't much of a relation between java and javascript: if you go by history, the java prefix was added just to gain the royalty of Java. Both are different in syntax, semantics and usages.

Similarities between java and visual basic?


What is the Difference between JavaScript and Java Applets?

Javascript is a scripting language that is object based code that makes it easier to work with objects. Java Applets is an applet that reads Java, which is different than Javascript, and compiles it. Java Applets are mostly known for games and can also be used for a website if you know what you are doing.

Do you need java compiler to execute HTML programs written in javascript?

No, Java and JavaScript are nothing to do with each other, JavaScript is a form of EMCAScript, not Java. Every modern browser comes with a JavaScript engine that is used to understand JavaScript. so there is no need for it, no.

What are differences between PHP and Java?

PHP and Java.. hummPHP is a programming language to make websites and scripts on the web.. while Java is an hardware programming language, please be advised that you can use Java applications on the web by using applets...But generally Java will be used to develop hardware applications..But if you meant JavaScript instead of Java:JavaScript is an client side language that help you change/modify your elements on your website without reloading page.

How to implement java script in java?

to implement javascript embed the statements between <script> n </script>,,, and include any scripting language. eg:<script LANGUAGE="javascript"> block of codes </script>

What is difference between js and java script?

js is the file name for javascript files. For eg. "Validation.js" which is a file containing javascript code. If you mean JSP then it is different which stands for Java Server Pages.

Does iPod touches have java script?

they have java< javascript and flash

How do you shortcut systemoutprintln in javascript?

There is no systemout object in JavaScript. Do you mean Java?

How do you disable javascript?

Javascript cannot be disabled but java can just go to Control Panel > Sun Java Panel > Disable

Are java and javascript the same?

Java and Javascript are different languages. Java was created by Sun MicroTech to use a strict programming language Javascript was created by Netscape to create an interactive web platform <Netscape Navigator 2.0>

What is the draw between java and java script?

No similarities. JavaScript was actually originally called Mocha, then LiveScript, and just wanted to hop on the bandwagon of popularity that Java was getting.

Can a java program run on the browser?

No it can't, this is the difference between Java and JavaScript (which don't have that much to do with one-another) Java is more like C in that it can on the web-server or on any computer really, but it is not like JavaScript which runs inside a sandbox inside the browser.

Does java script coding mean using it for Java programs only Can you use it for Unity or Game-maker?

Java and JavaScript are different, and quite unrelated, languages. JavaScript is not "for Java"; basically you use JavaScript to create special effects on Web pages (HTML pages).

Who markets javascript?

Nobody markets JavaScript, it's not a proprietary technology like Java is. In fact, it has no relation to Java. JavaScript is standardized and used by every web browser that supports scripting.

How can we use script tag in java?

You can't.The tag is part of HTML, and is used to include Javascript in a webpage. Java is not related to Javascript.

Difference between awt and java script?

AWT is a Java package for creating graphical user interfaces. JavaScript is a completely unrelated programming language.

What is java and java script?

Java is an object oriented language whereas Javascript is object base language.

Which language should you start first from java and java script?

Easy and simple . Java first , then javascript.

What are good Java script codes?

depending on the intention of the javascript codes you wish to write. there is much you can do with javascript but the only way to find out what "good Java script codes" are is to explore what you want the Javascript to do on the page.