You are here: Difference of & in perl and php « PHP Programming Language « IT news, forums, messages
Difference of & in perl and php

Posted by fritz-bayer@web.de on 10/19/06 11:41

Hello,

I'm porting a program from php to perl and discovered, that the bitwise
operator & seems to work differently, which I don't understand why.

I tested it with the values:

a=5543039447 and b=13

Then in perl the expressions:

$result= ($z & $a);

returns 2147483648.

But in php the same expression returns zero. Why is that and how can I
fix it?!

Fritz

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация