Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Something seems to have gone wrong here. Obviously Mark is different to Tony, so why does perl consider them equal?

0
Posted

Something seems to have gone wrong here. Obviously Mark is different to Tony, so why does perl consider them equal?

0

Mark and Tony are equal — numerically. We should be testing them as strings, not as numbers. To do this, simply substitute == for eq and everything will work as expected.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123