Question No: 5
Running your Perl scripts with a d switch will perform which task?
A. Invoke the Perl debugger
B. Send standard error to a file
C. Disable breakpoints
D. Display a stack trace
Answer: A
Topic 1, B
B
Question No: 6
Consider the following program code:
print(1 );
BEGIN { print(2 ); }
END { print(3 ); }
BEGIN { print(4 ); } END
{
package MyPackage; print(5 );
}
What is the result of executing this program code?
A. The code will output the following: 1 2 3 4 5
B. The code will output the following: 2 4 1 5 3
C. The code will output the following: 2 1 3 4 5
D. The code will output the following: 2 4 1 3
Answer: B
Question No: 7
Which one of the following choices uses the correct syntax for a valid array assignment?
A. @cities = Akron, Memphis, Ogden, Phoenix;
B. @cities =~ ("Akron, Memphis");
C. @cities =~ (Akron, Memphis, Ogden, Phoenix);
D. @cities = ("Akron");
Answer: D
Question No: 8
Consider the following program code:
$var = 10; package Alpha;
$var = 20;
{
package Beta;
$var = 30;
}
package Gamma;
$var = 40;
{
print $var;
}
What is the output of this code?
A. 10
B. 20
C. 30
D. 40
Answer: D
Question No: 9
Consider the following code:
%chars = ("a", "100", "b", "90", "c", "80");
Which one of the following choices will reverse the key/value pairing of the code?
A. reverse(%chars);
B. %chars = reverse(%chars);
C. reverse(%chars) = %chars;
D. invert(%chars);
Answer: B
Question No: 10
Consider the following program code:
%hash = (small => 8oz,
medium => 16oz, large => 32oz);
@keys = sort(keys(%hash));
for ($i = 0; $i < 3; $i++) { print($hash{$keys[$i]}\n);
}
What is the result of executing this program code?
A. The code will fail at line 1 because a hash cannot contain both numeric and string data.
B. The code will execute without error but will output nothing.
C. The code will output the following: 32oz
16oz 8oz
D. The code will output the following: large
medium small
Answer: C
Question No: 11
Consider the program code in the attached exhibit. What is the result of executing this program code?
A. The code will output the following: 50
B. The code will output the following: 0
C. The code will output the following: 5
D. The code will output the following: multiply(5, 10)
Answer: B
Question No: 12
Consider the following lines of code:
sub mySub {
$_ = @_[1];
$a = shift;
$b = shift;
return $a * $b * $_;
}
mySub(1,2,3);
What is the output of these lines of code?
A. No output results from this code.
B. 6
C. 2
D. 4
Answer: A
Question No: 13
Which of the following describes the functionality of the DBI tables method?
A. The tables method returns a list of all system tables in a database.
B. The tables method returns a list of all user-defined tables in a database.
C. The tables method returns a list of all tables in a database.
D. The tables method returns a list of all related tables in a database.
Answer: C
Question No: 14
Regular expressions are best used for which task?
A. To perform arithmetic functions
B. To determine whether a string matches a specific pattern
C. To perform spelling checks within text files
D. To output data to a text file
Answer: B
100% Abreast of the times CIW 1D0-437 Questions & Answers shared by Examcollectionplus, Get HERE: https://www.examcollectionplus.net/vce-1D0-437/ (New Q&As)