bitwise shift?

Tobiah toby at tobiah.org
Wed May 2 16:06:39 EDT 2007


Tobiah wrote:
> John Machin wrote:
>> On 26/04/2007 7:10 AM, Sherm Pendley wrote:
>>
>>> Shift left is *not* the same as multiplying by k. It is the same as 
>>> multi-
>>> plying by 2^k. 
>>
>> Where I come from, ^ is the exclusive-or operator. Of course YMMV in 
>> WV :-)
> 
> desktops:toby:ga> bc
> bc 1.06
> Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
> This is free software with ABSOLUTELY NO WARRANTY.
> For details type `warranty'.
> 2^3
> 8
> 

Wow, thunderbird displayed this to me as a true exponent, even
though it is an ascii message.  anyone else get this?


-- 
Posted via a free Usenet account from http://www.teranews.com




More information about the Python-list mailing list