Explain string comparison operators in perl.



Explain string comparison operators in perl...

Answer / Deepika Singh

Perl uses several operators for comparing strings, including `eq` (equal), `ne` (not equal), `lt` (less than), `gt` (greater than), `le` (less than or equal to), and `ge` (greater than or equal to). For example: `if ('apple' eq 'orange') { ... }` checks if the strings are equal.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More CGI Perl Interview Questions

How does a “grep” function perform?

1 Answers  


Difference between Perl and Mod_perl?

2 Answers  


Mention how many ways you can express string in Perl?

1 Answers  


What are prefix dereferencer? List them.

1 Answers  


List all the features of perl programming?

1 Answers  


Write a program to concatenate the $firststring and $secondstring and result of these strings should be separated by a single space.

1 Answers  


Which has highest precedence in between list and terms? Explain?

1 Answers  


Explain chomp?

1 Answers  


how to find a substring in a string without using substr built in functions, and print the substring found

3 Answers   Nokia,


What are scalars?

1 Answers  


What is the importance of perl warnings? How do you turn them on?

1 Answers  


Why do you use only Perl when there a lot of more languages available in market like C, Java?

1 Answers  


Categories