• 1. 
    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
  • 2. 
    When you're pattern matching, you describe the pattern using:

  • A string in double quotes
  • A MySQL select statement
  • A regular expression
  • A template
  • 3. 
    Which of the following operator encloses a string with-in invert quotes?

  • q{ }
  • qq{ }
  • qx{ }
  • enclose{}
  • 4. 
    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.
  • 5. 
    What will be printed by the code below?my @a = (0, 1, 2);my $b = @a;print $b;

  • 0
  • 1
  • 2
  • 3
  • 6. 
    Select comparison operator from the options.

  • *=
  • &&
  • !=
  • =
  • 7. 
    Which of the following variable context only happens inside quotes, or things that work like quotes?

  • Interpolative
  • List
  • Boolean
  • Void
  • 8. 
    When a string is used for numeral computations, perl converts it into

  • character
  • floating point number
  • number
  • boolean value
  • 9. 
    What will be printed by the code below?58% on 4261 times askedmy $val = 'x';print ref($val);

  • SCALAR
  • empty value
  • STRING
  • "not a reference"
  • 10. 
    How will you get the size of a Hash?

  • Using scalar context
  • using sizeof operator
  • Both of the above.
  • None of the above.
  • 11. 
    Which of the following code create a reference for a variable?

  • $ref = \$foo;
  • $ref = \@ARGV;
  • $ref = \%ENV;
  • $ref = \&PrintHash;
  • 12. 
    Scalar stores

  • Multiple value
  • Single value
  • Double value
  • Float value
  • 13. 
    In Perl, scalar variables always begin with a ________ sign.

  • #
  • @
  • %
  • $
  • 14. 
    Perl was first released in:

  • 1978
  • 1998
  • Perl hasn't yet been released
  • 1988
  • 15. 
    Which of the following operator checks if the value of two operands are equal or not, if values are not equal then condition becomes true?

  • ==
  • !=
  • <=>
  • >
  • 16. 
    The $_ variable

  • holds the last pattern matched.
  • holds the output field separator.
  • identifies the current command line argument.
  • none of the above is correct.
  • 17. 
    Perl is:

  • A type of interactive web page
  • A programming language
  • An application program
  • A relational database
  • 18. 
    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
  • 19. 
    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
  • 20. 
    ___ function is used for removing the last character from the line.

  • cut
  • chop
  • erase
  • split
  • 21. 
    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
  • 22. 
    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.
Report Question
warning
access_time
  Time