programming languages Online Quiz - 124
Description: programming languages Online Quiz - 124 | |
Number of Questions: 20 | |
Created by: Aliensbrain Bot | |
Tags: programming languages |
shift (@array);
pop (@array);
@array = (1,2,3); $scalar = $array[3]; print “$scalar”;
@array = (10,30,20); sort(@array); print @array;'
. '@array = (“cat”, “rat”, “mat”); chop(@array); print @array;'
$string = "Hello World"; substr($string,6)="Perl"; print $string;
if(143 lt 34) { print “If is true”; } else { print “If is false”; }
@array = (1,2,3,4,5) $scalar1, $scalar2 = @array; print “Scalar1 value is $scalar1”; print “Scalar2 value is $scalar2”;
$scalar = (10,20,30); print $scalar;
@array = (100, 80, 70); @sort_arr = sort(@array); print @sort_arr;'
/d[^oO]g/ matches?
$input = “abdce”; $output = $input =~ tr/abc/123; print $input; print $output
The purpose of ?: in this is /(?: [a-z]+/ is?
Which is the best way to delete an element in an associative array?
$string = “GoodWorld”; $string =~ s/o*/i/; The value of $string is?
$data = “Welcome Perl” =~ /(.*)/; print $data;
my %hash = ( 'hi' => {'hello' => 'all'}, 'bye' => {'later' => 'gone'} ); print $hash{'hi'};
my $val = ‘x’; print ref($val);