Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 3 of 3

Thread: (for beginners) Difference between Java and JavaScript

  1. #1
    Junior Member
    Join Date
    Oct 2013
    Posts
    7
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default (for beginners) Difference between Java and JavaScript

    If you�re a computer user, you might have heard about Java and JavaScript. While most of the people assume that there is no difference between Java and JavaScript, in reality they are totally different from each other. Many beginner programmers often get confused and mix up both Java & JavaScript. However, it is important to note the evolution of both of these languages took a totally different path. Are you reading this article to get your doubt clear? If yes, it is time to compare both of these languages and know what exactly makes these two similar looking languages differ from each other.

    Java:
    One of the key differences between both of these languages is that Java is a programming language, which is based on the C language. It derives most of its syntax from C and C++ language. Java can stand on its own while JavaScript must be used in consort with the HTML (Hyper Text Markup) document to function appropriately.

    Java was created first before JavaScript, which means Java was an inspiration behind the creation of JavaScript.

    JavaScript:
    On the other hand, JavaScript is nothing but an interpreted programming language; it is a scripting language that is dynamic and weakly typed with a whole host of first class functions. It is created by Netscape and it can�t create stand alone applications like Java, but resides on the internet browser. Most of the modern web browsers have inbuilt JavaScript. However, it is important to note that JavaScript based web pages can run only when you�ve JavaScript enabled within your web browser.

    Read More - http://www.socialpositives.com/2013/10/difference-between-java-and-javascript/


  2. #2
    Member
    Join Date
    Oct 2013
    Location
    Saint-Petersburg, Russia
    Posts
    35
    Thanks
    0
    Thanked 5 Times in 5 Posts

    Default Re: (for beginners) Difference between Java and JavaScript

    One of the key differences between both of these languages is that Java is a programming language, which is based on the C language.
    I wonder, what did you mean by "based on the C language". The only thing that resembles C is the syntax basics. But they are similar for Javascript.

    Java can stand on its own while JavaScript must be used in consort with the HTML (Hyper Text Markup) document to function appropriately.
    Rhino Javascript is executed in Java Virtual Machine and needs not any HTML. Node.JS is executed on its own. Javascript inside MongoDB too. Only Javascript used inside browsers has something to deal with HTML...

    You of course know, there is "javax.script" package in standard Java API which allows execute JavaScript code to manage java objects etc.

    Java was created first before JavaScript, which means Java was an inspiration behind the creation of JavaScript.
    Extremely doubtful conclusion. JavaScript was created as LiveScript without much thinking of Java at all. However, later the name was changed to attract developers. It is a kind of marketing...

    So I think your idea was good, but facts and reasoning need to be thoroughly revised.

  3. The Following User Says Thank You to rodiongork For This Useful Post:

    bssatani (November 8th, 2013)

  4. #3
    Member
    Join Date
    Apr 2012
    Posts
    164
    Thanks
    0
    Thanked 27 Times in 27 Posts

    Default Re: (for beginners) Difference between Java and JavaScript

    The only "inspiration" Java had on Javascript is the name. The company purchased the language and gave it a similar name. They were developed completely separately from one another.

Similar Threads

  1. Java Tutorial for Beginners
    By technologypartner in forum Java Programming Tutorials
    Replies: 0
    Last Post: March 17th, 2015, 04:55
  2. difference between Java Aplet and JavaScript?
    By bryanOnInternet in forum AWT / Java Swing
    Replies: 4
    Last Post: December 29th, 2012, 17:03
  3. Beginners Java Help !
    By Cluelius in forum Loops & Control Statements
    Replies: 4
    Last Post: October 22nd, 2012, 13:24
  4. where is the java tutorial for beginners
    By javaque in forum Java Theory & Questions
    Replies: 2
    Last Post: September 14th, 2011, 03:30
  5. JAVASCRIPT DATE DIFFERENCE PROBLEM
    By jai in forum Other Programming Languages
    Replies: 3
    Last Post: April 5th, 2011, 09:11

Tags for this Thread