Advertisement
 

Javascript Introduction

  • - Featured
Quiz
Assignments
  • - Table of Contents

Javascript initially had another name when JavaScript was created: "LiveScript." But at that time Java was very popular, so it was decided that it would help to position a new language as Java's "younger brother."Javascript is developed by Brendan Eich.

But as it evolved, JavaScript became a completely independent language with its own specification called ECMAScript, and now it has no relationship at all with Java. The programs are called scripts in this language. They can be written directly in the HTML of a web page and run as page loads automatically. Scripts are given as plain text and performed. No unique preparation or compilation is needed for them to operate. JavaScript is very distinct in this respect from another language called Java. Today, JavaScript can run on any device that has a special program called the JavaScript engine, not only in the browser but also on the server. The browser sometimes has an integrated engine called a "virtual machine JavaScript."

For example, JavaScript in the browser is able to:

Check Your Knowledge:


  1. What is JavaScript?
  2. JavaScript is both a client-side and a server-side scripting language that can be inserted into HTML pages and web browsers understand. JavaScript is also a programming language based on objects

  3. Enumerate the differences between Java and JavaScript?

    Java is a language of complete programming. JavaScript, on the other hand, is a coded program which can be introduced to HTML pages. These two languages are not interdependent at all and are intended for various purposes. Java is an object-programming oriented (OOPS) or a structured programming language such as C++ or C while JavaScript is a scripting language on the client side.

  4. Between JavaScript and ASP script, which is faster?

    JavaScript is faster. JavaScript is a language on the client side and therefore does not need the internet server support to perform. On the other hand, ASP is a language on the server side and is therefore always slower than JavaScript. Javascript is now a side language of the server (nodejs).

  5. Which company developed JavaScript?

    Netscape is the software company who developed JavaScript.

  6. What are the different types of errors in JavaScript?

    There are three types of errors:

    1. Load time errors:

      Errors that occur when loading a web page, such as incorrect syntax errors, are referred to as load time errors and dynamically generate errors.

    2. Run time errors:

      Errors that occur in the HTML language due to misuse of the command.

    3. Logical Errors:

      These are the errors that happen because of the bad logic performed on a distinct function.

  7. What is the difference between JavaScript and Jscript?

    Both are almost similar. JavaScript is developed by Netscape and Jscript was developed by Microsoft .

  8. Is JavaScript case sensitive? Give an example?

    Yes, JavaScript is case sensitive. For example, a function checkIn is not same as the function checkin.

  9. What are the various functional components in JavaScript?

    The different functional components in JavaScript are-
    First-class functions: JavaScript functions are used as objects of first class. Usually this implies that these functions can be passed to other functions as arguments, returned as values from other functions, allocated to variables or stored in data structures as well.
    Nested functions: The functions are called Nested functions, which are described within other functions. They are called the main function is invoked ' every time. '

  10. How are JavaScript and ECMA Script related?

    ECMA Script are like rules and guideline while Javascript is a scripting language used for web development.

  11. What is ECMAScript ?

    This is the official name given to the language standard that Netscape originally submitted to ECMA for standardization. Despite the official name this language is more commonly referred to as JavaScript.

  12. Choose the correct JavaScript syntax to change the content of the following HTML code. &ltp id="Talent"&gtTalentxoom
    1. document.getElement(“Talent”).innerHTML=”I am a Developer”;

    2. document.getElementById(“Talent”).innerHTML=”I am a Developer”;

    3. document.getId(“Talent”)=”I am a Developer”;

    4. document.getElementById(“Talent”).innerHTML=I am a Developer;

  13. When a user views a page containing a JavaScript program, which machine actually executes the script?
    1. The User's machine running a Web browser

    2. The Web server

    3. A central machine deep within Netscape's corporate offices

    4. None of the above

  14. ______ JavaScript is also called client-side JavaScript.
    1. Microsoft

    2. Navigator

    3. LiveWire

    4. Native

  15. __________ JavaScript is also called server-side JavaScript.
    1. Microsoft

    2. Navigator

    3. LiveWire

    4. Native

  16. What is the original name of JavaScript?
    1. LiveScript

    2. EScript

    3. Mocha

    4. JavaScript

Discussion