Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
When the user types something in response your prompt: Enter a word:(which by the way would be better without the "\n"), they type in a word, and then they hit Return; and when they hit Return an invisible newline character is entered into the input stream: Enter a word: Mahesh\nSo your $string1 variable will look like this: $string1 = "Mahesh\n"...and that will never be eq to the string "Mahesh" In reply to Re: Comparing Strings
by 7stud
|
|