243). What convenience does the following JavaScript code snippet provide?
let succ = function(x) x+1, yes = function() true, no = function() false;

[A] Functional behaviour
[B]Modular behaviour
[C] No convenience
[D]Shorthand expression

Show Answer

244). What does the following JavaScript code snippet do?
data.sort(function(a,b),b-a);

[A]Sort in the alphabetical order
[B]Sort in the chronological order
[C]Sort in reverse alphabetical order
[D] Sort in reverse numerical order

Show Answer

245). What is the code to be used to trim whitespaces?
data.sort(function(a,b),b-a);

[A]let trimmed = (l.trim() for (l in lines));
[B] let trimmed = (trim(l));
[C] let trimmed = l.trim();
[D] let trimmed = for(l in lines));

Show Answer

246). What will be the reaction when a catch clause has no conditionals?
data.sort(function(a,b),b-a);

[A]Takes it to be 0
[B]Takes it to be 1
[C]Takes it to be true
[D] Takes it to be false

Show Answer

247). When will the finally block be called?
data.sort(function(a,b),b-a);

[A]When there is no exception
[B]When the catch does not match
[C]When there is exception
[D]After try-catch execution

Show Answer

248). What is the return type of typeof for standard JavaScript objects?
data.sort(function(a,b),b-a);

[A]xml
[B]object
[C]dom
[D]html

Show Answer

249). Which method to use while working with XML fragments, instead of XML()?
data.sort(function(a,b),b-a);

[A]XMLInterface()
[B]XMLClass()
[C]XMLList()
[D]XMLArray()

Show Answer

250). Which of the following is the descendant operator?
data.sort(function(a,b),b-a);

[A]..
[B]…
[C]*
[D]@

Show Answer

251). Which of the following is an example to perform the most common XML manipulations using the XML objects invocation?
data.sort(function(a,b),b-a);

[A]insertChildBefore()
[B]insertChildAfter()
[C]appendChildAfter(…)
[D]appendChildBefore(…)

Show Answer

252). What is the code required to delete all “weight” tags?
data.sort(function(a,b),b-a);

[A]delete weight(pt).all;
[B] delete pt.element[all];
[C]delete pt;
[D]delete pt..weight;

Show Answer

253). What will be the output of the following JavaScript code?

[A]30
[B]10 20
[C]1020
[D]Error

Show Answer

254). What will be the output of the following JavaScript code?

[A]1020
[B]10 20
[C]30
[D]Error

Show Answer

255). What will be the output of the following JavaScript code?

[A]1000
[B]10
[C]10010
[D]Error

Show Answer

256). What will be the output of the following JavaScript code?

[A]true
[B]false
[C]error
[D]undefined

Show Answer

257). What will be the output of the following JavaScript code?

[A]10
[B]9.65
[C]9.6
[D]9.656

Show Answer

258). What will be the output of the following JavaScript code?

[A]8.70
[B]8.76
[C]8.00
[D]Error

Show Answer

259). What will be the output of the following JavaScript code?

[A]2.00
[B]2.10
[C]2.20
[D]2.30

Show Answer

260). What will be the output of the following JavaScript code?

[A]1.31
[B]1.20
[C]1.11
[D]1.41

Show Answer