Department of Computer Science and Engineering: Unit II - MCQ Bank
Department of Computer Science and Engineering: Unit II - MCQ Bank
c) script
d) link
Answer: a
5. A proper scripting language is a __________
a) High level programming language
b) Assembly level programming language
c) Machine level programming language
d) Low level programming language
Answer: a
6. The property of a primary expression is ____________
a) stand-alone expressions
b) basic expressions containing all necessary functions
c) contains variable references alone
d) contains only keywords
Answer: a
7. “An expression that can legally appear on the left side of an assignment expression.” is a well
known explanation for variables, properties of objects, and elements of arrays. They are called
a) Properties
b) Prototypes
c) Lvalue
d) Definition
Answer: c
8. The type of a variable that is volatile is _______________
a) Volatile variable
b) Mutable variable
c) Immutable variable
d) Dynamic variable
Answer: b
9. The generalised syntax for a real number representation is __________
a) [digits][.digits][(E|e)[(+|-)]digits]
b) [digits][+digits][(E|e)[(+|-)]digits]
c) [digits][(E|e)[(+|-)]digits]
d) [.digits][digits][(E|e)[(+|-)]digits]
Answer: a
10. JavaScript _________ when there is an indefinite or an infinite value during an arithmetic
computation.
a) Prints an exception error
b) Prints an overflow error
c) Displays “Infinity”
d) Prints the value as such
Answer: c
11. The statement a===b refers to _________
a) Both a and b are equal in value, type and reference address
b) Both a and b are equal in value
c) Both a and b are equal in value and type
d) There is no such statement
Answer: c
12. Assume that we have to convert “false” that is a non-string to string. The command that we use
is (without invoking the “new” operator).
a) false.toString()
b) String(false)
c) String newvariable=”false”
d) Both false.toString() and String(false)
Answer: d
13. A conditional expression is also called a _______________
a) Alternative to if-else
b) Immediate if
c) If-then-else statement
d) Switch statement
Answer: b
14. The “var” and “function” are __________
a) Keywords
b) Declaration statements
c) Data types
d) Prototypes
Answer: b
15. The enumeration order becomes implementation dependent and non-interoperable if_____
a) If the object inherits enumerable properties
b) The object does not have the properties present in the integer array indices
c) The delete keyword is never used
d) Object.defineProperty() is not used
Answer: a
16. What are the three important manipulations done in a for loop on a loop variable?
a) Updation, Incrementation, Initialization
b) Initialization,Testing, Updation
c) Testing, Updation, Testing
d) Initialization,Testing, Incrementation
Answer: b
17. What will be the step of the interpreter in a jump statement when an exception is thrown?
a) The interpreter stops its work
b) The interpreter throws another exception
c) The interpreter jumps to the nearest enclosing exception handler
d) The interpreter throws an error
Answer: c
18. The object has three object attributes namely ________
a) Class, parameters, object’s extensible flag
b) Prototype, class, objects’ parameters
a) date
b) Object
c) Array
d) String
Answer: a
24. Which of following statement is false about the space parameter in JSON.stringify()?
a) It controls spacing in the resulting JSON string
b) It is an optional parameter
c) It removes whitespace
d) All are false
Answer: c
25. Can you use a double quote inside a JSON string?
a) No, you should use single quotes
b) Yes, if you use the ascii code.
c) Yes, if it is escaped like ( \" )
d) Yes, you can use it without any special treatment
Answer: c
26. The MIME type of JSON is____________
a) application/json
b) application/x-json
c) application/javascript
d) text/json
Answer: a
27. What is the full form of SQL?
a) Structured Query List
b) Structure Query Language
c) Sample Query Language
d) None of these.
Answer: b
28. Which statement is used to delete all rows in a table without having the action logged?
a) DELETE
b) REMOVE
c) DROP
d) TRUNCATE
Answer: d
29. Which of the following is not Constraint in SQL?
a) Primary Key
b) Not Null
c) Check
d) Union
Answer: d
30. Which of the following statement is true?
a) TRUNCATE free the table space while DELETE does not.
b) Both TRUNCATE and DELETE statements free the table's space.
c) Both TRUNCATE and DELETE statement does not free the table's space.
d) DELETE free the table space while TRUNCATE does not.
Answer: a