Question 1
Question
How can you create an e-mail link?
Question 2
Question
colspan=n can be added to only what tag?
Question 3
Question
The following elements <header>, <footer>, <article>, <section> are the new elements in HTML5. These elements are called,
Answer
-
Control attributes
-
Semantic elements
-
Graphic elements
-
Multimedia elements
Question 4
Question
Which is not suited for game applications?
Answer
-
Canvas
-
Svg
-
Both A & B
-
None of the above
Question 5
Question
The canvas element has a DOM method it is called.
Answer
-
getContext
-
getId
-
getElement
-
None of the above
Question 6
Question
The default value of "position" attribute is _________.
Answer
-
inherit
-
relative
-
fixed
-
absolute
Question 7
Question
Which css property you will use if you want to add some margin between a border and its inner text ?
Answer
-
spacing
-
margin
-
padding
-
inner-margin
Question 8
Question
p {line-height: 150%;}.
What type of selector is used in this case?
Answer
-
class Selectors
-
element Selectors
-
id Selectors
-
none of the mentioned
Question 9
Question
By applying an ___________ a style can be applied to just a single tag.
Answer
-
class rule
-
element rule
-
id rule
-
none of the mentioned
Question 10
Question
A ___________ is used to define a special state of an element.
Answer
-
pseudo-tag
-
pseudo-element
-
pseudo-id
-
pseudo-class
Question 11
Question
Which of the following JavaScript function of String object returns the character at the specified index?
Answer
-
charAt()
-
charCodeAt()
-
concat()
-
indexOf()
Question 12
Question
What is the correct JavaScript syntax to write "Hello World"?
Answer
-
System.out.println("Hello World");
-
println ("Hello World");
-
document.write("Hello World");
-
response.write("Hello World");
Question 13
Question
Which of the following is not considered a JavaScript operator?
Question 14
Question
Which of the looping statements is/are supported by PHP?
i) for loop ii) while loop iii) do-while loop iv) foreach loop
Answer
-
(i) and (ii)
-
(i), (ii) and (iii)
-
All of the mentioned
-
None of the mentioned
Question 15
Question
What will be the output of the following php code
< ?php
$num = 1;
$num1 = 2;
print $num . "+". $num1 ;
?>
Question 16
Question
What will be the output of the following code?
< ?php
function track() {
static $count = 0;
$count++;
echo $count ;
}
track();
track();
track();
?>
Question 17
Question
PHP scripts are executed on _________
Question 18
Question
What will be the output of the following code?
$var = 10;
function fn ()
{
$var = 20;
return $var;
}
fn ();
echo $var;
Answer
-
10
-
20
-
Undefined Variable
-
Syntax Error
Question 19
Question
What will be the output of the following PHP code?
echo 30*5 . 7;
Answer
-
150.7
-
1507
-
171
-
error will occur
Question 20
Question
In your PHP application you need to open a file. You want the application to issue a warning
and continue execution, in case the file is not found. The ideal function to be used is:
Answer
-
include()
-
require()
-
nowarn()
-
getFile(false)
Question 21
Question
Which of the following is used in perl?
Answer
-
else if
-
elseif
-
elsif
-
elif
Question 22
Question
What will be printed by the Perl code below?
my @a = (0, 1, 2);
my $b = @a;
print $b;
Question 23
Question
What gets printed in Perl?
my $str = 'a\\b\n';
print $str;
Answer
-
ab(newline)
-
a\b(newline)
-
a\b\n
-
a\\b(newline)
-
a\\b\n
Question 24
Question
What gets printed in Perl?
my $a = '123';
my $b = '0123';
if ($a == $b) {
print "same";
} else {
print "different";
}
Answer
-
same
-
different
-
the code is ill-formed
Question 25
Question
What will the @b array consist of in Perl?
my @a = (10, 5, 1);
my @b = sort @a;
Answer
-
(1, 5, 10)
-
(10, 5, 1)
-
(1, 10, 5)
-
(5, 10, 1)
-
( )
Question 26
Question
What will be printed in Perl?
print 'a';
BEGIN {
print 'b';
}
sub foo {
print 'c';
}
Question 27
Question
what does the following python code do?
def a(b, c, d): pass
Answer
-
defines a list and initializes it
-
defines a function, which does nothing
-
defines a function, which passes its parameters through
-
defines an empty class
Question 28
Question
What is the output of the following python code ?
print(type([1,2]))
Answer
-
<class 'tuple'>
-
<class 'int'>
-
<class 'set'>
-
<class 'dictionary'>
-
<class 'list'>
Question 29
Question
what is the output of the below program in python?
a = [1,2,3,None,(),[],]
print(len(a))
Question 30
Question
What gets printed in python?
x = 4.5
y = 2
print(x//y)
Question 31
Question
What gets printed in Python?
print(r"\nwoow")
Answer
-
new line then the string: woow
-
the text exactly like this: r"\nwoow"
-
the text like exactly like this: \nwoow
-
the letter r and then newline then the text: woow
-
the letter r then the text like this: nwoow
Question 32
Question
What gets printed in Python?
print(0xA + 0xa)
Answer
-
0xA + 0xa
-
0xA 0xa
-
14
-
20
-
0x20
Question 33
Question
What gets printed in Python?
name = "snow storm"
print(name[6:8])
Answer
-
st
-
sto
-
to
-
tor
-
Syntax Error
Question 34
Question
Which numbers are printed in Python?
for i in range(2):
print(i)
for i in range(4,6):
print(i)
Answer
-
2, 4, 6
-
0, 1, 2, 4, 5, 6
-
0, 1, 4, 5
-
0, 1, 4, 5, 6, 7, 8, 9
-
1, 2, 4, 5, 6
Question 35
Question
What gets printed in Python?
x = "foo "
y = 2
print(x + y)
Answer
-
foo
-
foo foo
-
foo 2
-
2
-
An exception is thrown
Question 36
Question
What gets printed in Python?
foo = (3, 4, 5)
print(type(foo))
Answer
-
<class 'int'>
-
<class 'list'>
-
<class 'tuple'>
-
<class 'dict'>
-
<class 'set'>
Question 37
Question
What gets printed in Python?
names = ['Amir', 'Barry', 'Chales', 'Dao']
print(names[-1][-1])
Question 38
Question
What gets printed in Python?
numbers = [1, 2, 3, 4]
numbers.append([5,6,7,8])
print(len(numbers))
Answer
-
4
-
5
-
8
-
12
-
An exception is thrown
Question 39
Question
Which of the following data structures in Python can be used with the "in" operator to check if an item is in the data structure?
Answer
-
list
-
set
-
dictionary
-
All of the above
-
None of the above
Question 40
Question
What gets printed in Python?
my_tuple = (1, 2, 3, 4)
my_tuple.append( (5, 6, 7) )
print(len(my_tuple))
Answer
-
1
-
2
-
5
-
7
-
An exception is thrown
Question 41
Question
What gets printed in Python?
x = sum(range(5))
print(x)
Answer
-
4
-
5
-
10
-
15
-
An exception is thrown
Question 42
Question
Which of the following is the way to create comments in PHP?
Answer
-
// commented code to end of line
-
/* commented code here */
-
# commented code to end of line
-
all of the above
Question 43
Question
What gets printed in PHP?
$var = 'false';
if ($var) {
echo 'true';
} else {
echo 'false';
}
Question 44
Question
Which of the following is used to declare a constant in PHP?
Answer
-
const
-
constant
-
define
-
#pragma
-
def
Question 45
Question
What gets printed?
<?php
$RESULT = 11 + 011 + 0x11;
echo "$RESULT";
?>
Question 46
Question
Which tags are most commonly used by search engines?
Answer
-
Paragraph
-
Heading
-
Title
-
All of above
Question 47
Question
Banners, buttons, dividers, clipart and other simple images usually work best as ?
Question 48
Question
Which built-in method returns the character at the specified index?
Answer
-
characterAt()
-
getCharAt()
-
charAt()
-
None of the above
Question 49
Question
var city = new Array("delhi", "agra", "akot", "aligarh","palampur");
console.log(city.pop());
Question 50
Question
What does isNaN function do?
Answer
-
Returns false if the argument is not a number.
-
Returns true if the argument is not a number.
-
Returns true if the argument is a number.
-
None of the above
Question 51
Question
CDN stands for_______
Answer
-
Content Distribution Network
-
Common Distribution Network
-
Collective Distribution Network
-
None of these