Development - Java Script Test

Test Instructions :

1. The Test is 1hr duration.
2. The Test Paper consists of 30 questions. The maximum marks are 30.
3. All the questions are multiple choice question type with three options for each question.
4. Out of the three options given for each question, only one option is the correct answer.
5. Each question is allotted 1 mark for each correct response.
6. 0.25 will be deducted for incorrect response of each question.
Start Test

   Time Left : 00 : 30    : 00

"++" is __________ type of operator.





"Add and Assignment" operator is shown by this symbol.





The syntax of capture events method for document object is ______________





JavaScript was invented at _______ Lab .





In March 1996, _______________ was released, featuring support for JavaScript.





Which of the following is not considered a JavaScript operator?













If the values on either side of '+' operator are numerical values then ___________.




Which of the following is considered as End of Single line comment ?





Single Line Comment Starts with _________ Symbol.





<!DOCTYPE html>
            var x = "5";
            var y = 6;
            var z = x + y;
            document.write(x + "<br>");
            document.write(y + "<br>");
            document.write(z + "<br>");

Guess output of the following code.





Variable declared without a value will have the value ______________.Eg.

var num;








<script type="text/javascript">

What will be the Output of the above Code ?





"===" operator is _______________.





<!DOCTYPE html>
            var x = 5;
            var y = 6;
            var z = 5 + 6;
            document.write(x + "<br>");
            document.write(y + "<br>");
            document.write(z + "<br>");

Guess output of the following code.










Java Script have following type of Comment(s) -





<script type="text/javascript">
var s = "9123456 or 80000?";
var pattern = /\d{4}/;
var output = s.match(pattern);

What is the output?





JavaScript Code can be called by using _________.





What type of value gets printed if we add following two variables.

var a = "1";
var b = 5;






Group of JavaScript Statements is called as _________.





Comments in JS are ignored by ____________.





A ________ object is a reference to one of the classes in a Java package, such as netscape.javascript .





The syntax of close method for document object is ______________





What is mean by "this" keyword in javascript?





If para1 is the DOM object for a paragraph, what is the correct syntax to change the text within the paragraph?





Adding String and Integer always results in _________.





<!DOCTYPE html>
            var num1 = 1;
            var num2 = 1;
            var num3 = "1" + num1 + num2;
            document.write(num1 + "<br>");
            document.write(num2 + "<br>");
            document.write(num3 + "<br>");

Guess output of the following code.





It is good to include JS code inside footer section in order to speed up the Page loading time of Webpage.



Which of the following is not JavaScript Data Types?





The development environment offers which standard construct for data validation





JavaScript contains a _________________ that assigns a value to a variable based on some condition.





Multiple JS statements are written inside pair of ________ to form a statement block.





Local Variables are destroyed after execution of function.



Choose the client-side JavaScript object?





+Infinity in JS gets added with +Infinity then output of the code will be -




When you assign a text value to a variable, we put text value in the pair of _________.




Variable can hold ________ value at a time





How does JavaScript store dates in a date object? 





Assignment Operators is following type of operator ______________.





<script type="text/javascript">
// document.write("<h1>Heading</h1>");

Which of the statement will be neglected by Browser ?











Is it necessary to use "var" keyword while declaring variable.



JavaScript is interpreted by _________





Integer Variable + Character Variable + Undefined Variable = ______________ Value





______ attribute is used to specify the character encoding used in an external script file.





Scripting language are




"async" attribute is used to include External JS Code Asynchronously.

<script src="main.js" async="async"></script>




What will be printed inside webpage ?

var message="Hello JS";






Spaces,Punctuation marks are called as __________ Symbols in JavaScript.





Choose the server-side JavaScript object?





The output for the following code snippet would most appropriately be

var a=5 , b=1
var obj = { a : 10 }






            var name = "John Doe";
            var name = 123;
            document.write(name + "<br>");

Is it possible to change the type of value after re-assignment.





Non Initialized Variable have value "undefine", What value be printed in following case.

var carname="Volvo"; 
var carname;






/* This is Simple Comment */

This is the example of ____________ Comment.



JavaScript was originally developed under the name _______.





Initialization of variable can be done by writing _____ operator in between variable name and operand value.





All modern browsers supports JS.



JavaScript is also called as _____________.





Guess the ternary operator used in the following example !!!

marks = (mark<35)?"Fail":"Pass";






Comment Statement is _________________ type of statement.





_________ is a wrapped Java array, accessed from within JavaScript code.





<script src="../main.js"></script>

This code will include External JS inside your webpage.



JavaScript syntax to change the content of the following HTML code





The escape sequence ‘f’ stands for





Which tag(s) can handle mouse events in Netscape?





Which of the following is not a comparison operator ?






<script type="text/javascript">
document.write("<h1>This is a heading</h1>");
document.write("<p>This is a paragraph.</p>");
document.write("<p>This is another paragraph.</p>");

HTML Tags are allowed inside JS. Is this error free code ?



Variable name contain following type of characters -1. Alphabet2. Digits3. Underscore4. Special ChractersSelect the correct option.





JavaScript entities start with _______ and end with _________.





            var x = 12.45;
            var y = 1;
            var z = '8' + x + y;
            document.write(z + "<br>");

Value of Z is





When a user views a page containing a JavaScript program, which machine actually executes the script?





Microsoft Developed a compatible dialect of JavaScript called _____________.





var num=20;

Above Statement is called as __________ Statement. Select all the appropriate options.





Vriables declared inside function are visible _______________.





var str = "Str";
var num = 10;
var output = str + num;

What will be the value of Variable 'output' ?





<script type="text/javascript">

What is the output.?





JavaScript is Case Sensitive !!Say True or False



Which best explains getSelection()?





Underscore can be used as first letter while declaring variable in JavaScript.



<script type="text/javascript">
        document.Write("<h1>This is a heading</h1>");

Above Code contain one executive Statement. Guess the Output of the Above Code.





JavaScript is invented by ________.





Which company developed JavaScript?





What is the correct JavaScript syntax to write "Hello World"?





Which of the following is not a JSON type?





Is it possible to nest functions in JavaScript?



"+=" operator can operate on following data values.





What does the tag do?





Which of the following function of Array object returns the last (greatest) index of an element within the array equal to the specified value, or -1 if none is found?





How to create a Date object in JavaScript?





A hexadecimal literal begins with





During addition of two numbers , suppose one of the number is NaN then output of the following code will be ?





JavaScript is designed for following purpose 





JavaScript is ______ Side Scripting Language.





Multiple Declarations of variables are separated by ___________ symbol





var var1 = "Pritesh";

Above variable can store value of type.





We can declare all type of variables in JavaScript with the keyword _____________.





What is the correct syntax for referring to an external script called " abc.js"?





In JavaScript, Window.prompt() method return true or false value ?



Person XYZ wrote his name and date of code creation at the start , What kind of comment he has written ?





The script tag must be placed in





Which of the following operator is used to concatenate two strings.





____________ is used to assign value to the variable.





  • Click the 'Submit Test' button given in the bottom of this page to Submit your answers.
  • Test will be submitted automatically if the time expired.
  • Don't refresh the page.