What is the difference between chop & chomp functions in perl?
Answer Posted / nagaraju kancherla
chop() removes the last character from a scalar value.
chomp() checks whether the last characters of a string or
list of strings match the input line separator defined by
the $/ system variable. If they do, chomp removes them.
| Is This Answer Correct ? | 25 Yes | 5 No |
Post New Answer View All Answers
Perl regular expressions are greedy" what does this mean?
What are the different ways to run cgi?
Explain grooving and shortening of arrays and splicing of arrays?
How to start perl in interactive mode?
Which functions in perl allows you to include a module file. State their differences.
What rules must be followed by modules in perl.
What is v-strings?
What is the function of cgiwrap in cgi programming?
How to read a file into a hash array?
Why we use CGI?
What is the function of virtual documents in cgi programs?
How many types of operators are used in the Perl?
You want to add two arrays together. How would you do that?
How do I replace every character in a file with a comma?
Explain perl.