Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Perl Programming Quiz #2 - Basic Perl, Quizzes of Information Technology

A quiz for www 181 - perl programming course, covering topics such as references, regular expressions, modules, object-oriented programming, and debugging. The quiz includes questions about the ref() function, variable interpolation with the translation operator, the /g option of the substitution operator, modules and pragmas, object-oriented programming concepts, and debugging.

Typology: Quizzes

Pre 2010

Uploaded on 08/04/2009

koofers-user-l8u
koofers-user-l8u 🇺🇸

5

(1)

10 documents

1 / 2

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
WWW 181 – Perl Programming, Quiz #2, Basic Perl
Name ________________________________
Instructions - include name, Class, Section BOLD your answers. Print and hand in next
class.
References
1) What is a reference?
2) How many types of references are there?
3) What does the ref() function return if passed a non-reference as a parameter?
4) What notation is used to dereference a reference value?
5) What is an anonymous array?
6) What is a nested data structure?
7) What will the following line of code display?
print("${\ref(\(1..5))}");
Regular Expressions
8) Can you use variable interpolation with the translation operator?
9) What happens if the pattern is empty?
10) What variable does the substitution operator use as its default?
11) Will the following line of code work?
m{.*];
12) What is the /g option of the substitution operator used for?
13) What does the \d meta-character sequence mean?
14) What is the meaning of the dollar sign in the following pattern?
/AA[.<]$]ER/
pf2

Partial preview of the text

Download Perl Programming Quiz #2 - Basic Perl and more Quizzes Information Technology in PDF only on Docsity!

WWW 181 – Perl Programming, Quiz #2, Basic Perl

Name ________________________________ Instructions - include name, Class, Section BOLD your answers. Print and hand in next class. References

  1. What is a reference?
  2. How many types of references are there?
  3. What does the ref() function return if passed a non-reference as a parameter?
  4. What notation is used to dereference a reference value?
  5. What is an anonymous array?
  6. What is a nested data structure?
  7. What will the following line of code display? print("${\ref((1..5))}"); Regular Expressions
  8. Can you use variable interpolation with the translation operator?
  9. What happens if the pattern is empty?
  10. What variable does the substitution operator use as its default?
  11. Will the following line of code work? m{.*];
  12. What is the /g option of the substitution operator used for?
  13. What does the \d meta-character sequence mean?
  14. What is the meaning of the dollar sign in the following pattern? /AA[.<]$]ER/
  1. What is a word boundary? Modules
  2. What is a module?
  3. How is a module different from a library?
  4. What is the correct file extension for a module?
  5. What is a pragma?
  6. What is a symbol table?
  7. How can you create a variable that is local to a package? OOP
  8. What is an object?
  9. What is a class?
  10. What is a property?
  11. What does is the bless() function used for?
  12. What does the package keyword do?
  13. Why is it good to use anonymous hashes to represent objects instead of regular arrays?
  14. How can you create a function that is available to all classes in your script? Debugging
  15. What is a logic error?
  16. What is a compile-time error?
  17. What are the two places that the switches can be specified?
  18. What switch should always be used?