Perl Online Quiz


Following quiz provides Multiple Choice Questions (MCQs) related to Perl. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Q 2 - Which of the following variable context only happens inside quotes, or things that work like quotes?

A - Interpolative

B - List

C - Boolean

D - Void.

Answer : A

Explanation

Interpolative − This context only happens inside quotes, or things that work like quotes.

Answer : B

Explanation

To remove an element from the hash you need to use delete function.

Q 5 - Which of the following operator checks if the value of two operands are equal or not, if yes then condition becomes true?

A - ==

B - !=

C - <=>

D - >

Answer : A

Explanation

== − Checks if the value of two operands are equal or not, if yes then condition becomes true.

Q 6 - Which of the following operator returns true if the left argument is stringwise greater than the right argument?

A - lt

B - gt

C - le

D - ge

Answer : B

Explanation

gt − Returns true if the left argument is stringwise greater than the right argument.

Q 7 - Which of the following operator encloses a string with-in single quotes?

A - q{ }

B - qq{ }

C - qx{ }

D - enclose{}

Answer : A

Explanation

q{ } − Encloses a string with-in single quotes.

Answer : A

Explanation

Lexical variables are private variables created using my operator.

perl_questions_answers.htm
Advertisements