By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,851 Members | 1,410 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,851 IT Pros & Developers. It's quick & easy.

Perl math question

P: 2

When I do this in Perl:

if ((35/26) == (0.35/0.26)) {
print "equal\n";
else {
print "not equal\n";

I got "not equal". Does anyone know why? and solution?


Jan 23 '08 #1
Share this Question
Share on Google+
3 Replies

Expert 2.5K+
P: 4,059
good question. If you get no answer here ask over on and see if one of the gurus over there has an explanation. I would like to hear what the explanation is.
Jan 23 '08 #2

P: 2
I found a simliar question in is the link to that question:

Thanks for help!
Jan 23 '08 #3

Expert 2.5K+
P: 4,059
Cool. I should have known that, I have seen this problem before but the reason escaped me. Thanks for posting back.
Jan 23 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.