Q.1
___ function is used for removing the last character from the line.
  • cut
  • chop
  • erase
  • split
Q.2
What will be the value in the variable $a after these two statements: $a = "Happy"; $a = "Sunday";?
  • Happy Sunday"
  • "HappySunday"
  • "Happy"
  • "Sunday"
Q.3
When a string is used for numeral computations, perl converts it into
  • character
  • floating point number
  • number
  • boolean value
Q.4
Select comparison operator from the options.
  • *=
  • &&
  • !=
  • =
Q.5
Scalar stores
  • Multiple value
  • Single value
  • Double value
  • Float value
Q.6
What output will be generated by this statement: print("Hello\nworld\n\nThis is Perl\n");?
  • Hello worldThis is Perl
  • HelloworldThis is Perl
  • Hello World This is Perl
  • Helloworld\n\nThis is Perl
Q.7
What will be printed by the code below?my @a = (2);my $b = @a;print $b;
  • 0
  • 1
  • 2
  • 3
Q.8
What will be printed by the code below?my $val = {};print ref($val);
  • empty value
  • ARRAY
  • HASH
  • SCALAR
Q.9
In Perl, scalar variables always begin with a ________ sign.
  • #
  • @
  • %
  • $
Q.10
In Perl, the following will result in which of the following, if the prize is currently "5 dollars" print 'You won $prize';
  • You won $5.00
  • You won 5 dollars
  • You won $prize
  • You won $5
Q.11
The value of the expression $yards += 10
  • is 10.
  • is true.
  • cannot be determined from the information given.
  • relies on which command line arguments were used.
Q.12
The $_ variable
  • holds the last pattern matched.
  • holds the output field separator.
  • identifies the current command line argument.
  • none of the above is correct.
Q.13
Which of the following is used in perl?
  • else if
  • elseif
  • elsif
  • elif
Q.14
What will be printed by the code below?ontimes askedmy $val = 'x';print ref($val);
  • SCALAR
  • empty value
  • STRING
  • "not a reference"
Q.15
Perl was first released in:
  • 1978
  • 1998
  • Perl hasn't yet been released
  • 1988
Q.16
Which of these is NOT available for Perl:
  • Perl, legally, for free
  • Individual and site licenses
  • Full documentation of the language which you can print out yourself
  • A Carribean cruise in 2006 on which you can meet some of the Perl gurus.
Q.17
The statement open (FH,"abc.txt");
  • opens the file abc.txt for overwriting
  • opens the file abc.txt for reading
  • contains an error, so won't compile
  • opens the file abc.txt for appending
Q.18
The printf format "%6.2f" displays a number …
  • At least six columns wide in total, with two figures after the decimal place
  • Exactly six digits before the decimal place, and two digits after
  • At least six digits before the decimal place, and two digits after
  • Exactly six columns wide in total, with two figures after the decimal place
Q.19
Perl is:
  • A type of interactive web page
  • A programming language
  • An application program
  • A relational database
Q.20
When you're pattern matching, you describe the pattern using:
  • A string in double quotes
  • A MySQL select statement
  • A regular expression
  • A template
0 h : 0 m : 1 s