NAME

Question types


Start with


Question limit

of 83 available terms

Print test

83 Matching questions

  1. What are back-quotes
  2. $var > 10
  3. what is the symbol for any non digit character when using regular expressions
  4. What does the symbol () mean in regular expressions
  5. What does a string with the following evaluate to '00'
  6. Arithmetic
    $a / $b
  7. Disadvantage of PERL
  8. Create Perl Program
  9. \n
  10. What does the symbol \b mean in regular expressions
  11. Assignment
    $var = 5
  12. $str eq "Word"
  13. @_
  14. The defined function
  15. close()
    close (FILEHANDLE)
    Eg close (INFILE);
  16. $!
  17. Arithmetic
    $a - $b
  18. what is the symbol for the concatenation operator
  19. What does the symbol ^ mean in regular expressions
  20. var <= 10
  21. What does the symbol ? mean in regular expressions
  22. $var < 10
  23. Assignment
    $var--
  24. Assignment
    $var++
  25. print()
    print ($var)
  26. If ($colour eq "red") {print ("C1\n");}
  27. Logical
    CONDITION1 && CONDITION2
  28. chop()
    chop ($var)
  29. @ARGV
  30. what does the symbol * mean in regular expressions
  31. Logical
    CONDITION1 || CONDITION2
  32. \s
  33. What is a single quoted string.
  34. $var >= 10
  35. Assignment
    $var -= 2
  36. else {print ("C4\n");}
  37. $0
  38. what is the symbol for any non-whitespace character when using regular expressions
  39. $#array
  40. scalar()
    @array = (0,1,2,3,4);
    $number = scalar (@array);
    print ("Array Size = $number\n");
  41. my
  42. what is the symbol for any word character when using regular expressions
  43. What is a double quoted string
  44. what is the symbol for any digit character when using regular expressions
  45. Initiate Perl
  46. in regular expressions what does the s/// do
  47. in regular expressions what does //g mean
  48. cut($name=<STDIN>)
  49. split()
    split(/pattern/, $variable)
    Eg.
    #!/usr/local/bin/perl;
    $str = "1+3+6+4+5";
    @num = split(/\+/, $str);
    $count = scalar(@num);
    print ("The array has $count elements\n");
    print ("The second element of the array is $num[1]\n");
  50. what is the symbol for any white space character when using regular expressions
  51. elsif ($colour eq "green") {print ("C2\n");}
  52. Why PERL?
  53. $^O
  54. what is the symbol for any non-word character when using regular expressions
  55. Array Data
  56. Last statement
    last;
  57. PERL syntax (how words are put tgt)
  58. Scalar Data
  59. For loop
    $sum = 0;
    for ($i=0; $i<=100; $i++) { $sum = $sum + $i; } print ("Sum = $sum\n");
  60. chomp($name=<STDIN>)
  61. What does a string with the following evaluate to '0' or ''
  62. Advantage of PERL
  63. in relation expressions what does //i mean
  64. What does the symbol + mean in regular expressions
  65. $var = <FILEHANDLE>;
  66. Arithmetic
    $a % $b
  67. Assignment
    $var += 3
  68. \t
  69. File Handling
    open()
    open(FILEHANDLE, "test.txt")
    open(FILEHANDLE, ">test.txt")
  70. While loop
    $first var = 1;
    while ($firstVar <=10) {firstVar++};
    print ("outside:firstVar = $firstVar\n");
  71. Arithmetic
    $a + $b
  72. $_
  73. Relational Operators
  74. Logical
    ! CONDITION
  75. $str *ne "Word"
  76. In regular expressions what does the symbol . mean
  77. $a =~s/hate/love/
  78. what symbol is the {} in regards regular expressions
  79. PERL
  80. $a =~ /pat/
  81. What does the symbol $ mean in regular expressions
  82. Arithmetic
    $a * $b
  83. $a !~ /pat/
  1. a Less than or equal to
  2. b A literal string that prints exactly what it shows.
  3. c # If $colour = red, print as C1
  4. d Stores error messages returned from OS.
  5. e open(FILEHANDLE, "test.txt")
    - opens a file and link it to FILEHANDLE for reading

    open(FILEHANDLE, ">test.txt")
    - opens a file and link it to FILEHANDLE for writing to the file.
  6. f True if CONDITION1 is true or CONDITION2 is true
  7. g decrement $var by 1 and assign to $var
  8. h Greater than or equal to
  9. i Stores all arguments passed to a subroutine.
  10. j It is quantifier and specifies how elements we are looking for of a said character.
  11. k [^A-Za-z0-9_], \W
  12. l - Generally slower than a compiled program
  13. m Zero or one of the previous token
  14. n Sum of $a and $b
  15. o # If not, print C3
  16. p true
  17. q Word boundary anchor
  18. r Group, which is used to make a group of tokens that can be quantified as a unit
  19. s increment $var by 1 and assign to $var
    (equal to $var+1 then run program again)
  20. t - return an array constructed by using the pattern as a delimiter to distinguish elements in $variable

    prints:
    The array has 5 elements
    The second element of the array is 3
  21. u match any single character
  22. v $i=0; = CONDITION1 = set initial value of loop
    $i<=100; = CONDITION2 = decide is loop continue/stop
    $i++ = CONDITION3 = update loop variable
  23. w Zero or more of the previous token
  24. x Tells you the index of the last element of an array.
  25. y - Scalar variable begins with ($)
    - Any combination of letters, numbers, underscores
    Eg $name = "Bob"; #assignment of variable- name
    Eg $number = 123; assignment of variable- number
  26. z True if $a does not contain pattern "pat"
  27. aa [^0-9], \D
  28. ab Close the file associated with FILEHANDLE
  29. ac A string that will replace variable names with their values.
  30. ad Less than
  31. ae reads data into a variable and strips the ending character if it is a newline character.
  32. af Start of a string anchor
  33. ag - File name with suffix.pl
    - Text editor such as Windows Notepad/ UltraEdit
  34. ah # read one line from the file
    Eg $line=<INFILE>;
  35. ai reads data into a variable and strips the ending character no matter what it is.
  36. aj chops off the last character of $var
  37. ak Greater than 10
  38. al [A-Za-z0-9_], \w
  39. am # If not, $colour = green, print as C2
  40. an Remainder of $a divided by $b
  41. ao back quotes allow us to capture the return of a command by placing the command inside the series of back-quotes.
  42. ap One or more of the previous token
  43. aq True if $a contains pattern "pat"
  44. ar false
  45. as - Free
    - Easier to learn than C
    - Does not require a special compiler (Interpretive, not compiled)
  46. at Product of $a times $b
  47. au Stores command that ran the current script.
  48. av - Comments begin with (#).
    Eg # I'm a comment
    - Statements must end with (;)
    Eg print ("I am learning Perl.\n");
  49. aw [0-9], \d
  50. ax Difference of $a and $b
  51. ay True if CONDITION is not true
  52. az - Input e.g. "perl myprogram.pl" under DOS or Unix
  53. ba increase $var by 3 and assign to $var
  54. bb End of a string anchor
  55. bc decrease $var by 2 and assign to $var
  56. bd Case insensitive match
  57. be Stores the last thing read by Perl. It is the default variable for many functions.
  58. bf All white spaces
  59. bg assign 5 to $var
  60. bh - Easy to run
    - Efficient in processing biological seq data
  61. bi .
  62. bj - Arrays of scalar denoted with (@)
    - index always start at 0
    Eg @array = (1,2,3);

    Eg
    @students = ("Bob", "John", "Mary");
    (if we want Mary)
    print ("$students[2]\n");
  63. bk exits the most inner loop
  64. bl Returns false if the variable name has not been defined, and true if the variable name has been defined.
  65. bm - Check if the ouput is true/ not true
  66. bn Stores the name of the OS.
  67. bo True if both CONDITION1 and CONDITION2 are true
  68. bp Not equal to
  69. bq Newline
  70. br Quotient of $a divided by $b
  71. bs prints the value of $var to screen
  72. bt Tab
  73. bu Stores all command line arguments
  74. bv Program prints:
    outside: firstVar = 11
  75. bw Array Size = 5

    scalar() determines size of array
  76. bx [\t \r\n\f], \s
  77. by It is the substitution operator, the string to be matched goes between the first set of slashes and the value to replace it with goes in the second string.
  78. bz - Practical Extraction and Report Language
    - allows easy manipulation of files
    - process text information
  79. ca Makes a local variable.
  80. cb Equal to
  81. cc [^\t \r\n\f],\S
  82. cd Replace occurences of 'hate' with 'love' in $a
  83. ce Global; match as many times as possible within the string.