[Tutor] Bit Manipulations

Praveen Pathiyil ppathiyi@cisco.com
Wed, 4 Jul 2001 11:55:19 +0530


This is a multi-part message in MIME format.

------=_NextPart_000_00A1_01C10480.32A6C600
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Actually i was a bit lazy. I checked out the bitwise operators. But the =
problem for me is that the input is a hex value. So do i have to convert =
that into an integer before i apply the bitwise operators ?

Thx,
Praveen.
  ----- Original Message -----=20
  From: Praveen Pathiyil=20
  To: tutor@python.org=20
  Sent: Wednesday, July 04, 2001 11:36 AM
  Subject: [Tutor] Bit Manipulations


  Hi All,

          Where will i get some info about bitwise operations in python =
? I am trying to determine whether the MSB of a byte is 0 or 1.

  Thanks,
  Praveen.

------=_NextPart_000_00A1_01C10480.32A6C600
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Diso-8859-1" =
http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.3103.1000" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV>Actually i was a bit lazy. I checked out the bitwise operators. But =
the=20
problem for me is that the input is a hex value. So do i have to convert =
that=20
into an integer before i apply the bitwise operators ?</DIV>
<DIV>&nbsp;</DIV>
<DIV>Thx,</DIV>
<DIV>Praveen.</DIV>
<BLOCKQUOTE=20
style=3D"BORDER-LEFT: #000000 2px solid; MARGIN-LEFT: 5px; MARGIN-RIGHT: =
0px; PADDING-LEFT: 5px; PADDING-RIGHT: 0px">
  <DIV style=3D"FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV=20
  style=3D"BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: =
black"><B>From:</B>=20
  <A href=3D"mailto:ppathiyi@cisco.com" =
title=3Dppathiyi@cisco.com>Praveen=20
  Pathiyil</A> </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>To:</B> <A =
href=3D"mailto:tutor@python.org"=20
  title=3Dtutor@python.org>tutor@python.org</A> </DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Sent:</B> Wednesday, July 04, 2001 =
11:36=20
  AM</DIV>
  <DIV style=3D"FONT: 10pt arial"><B>Subject:</B> [Tutor] Bit =
Manipulations</DIV>
  <DIV><BR>&nbsp;</DIV>
  <DIV>Hi All,</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Where will i get some info =
about=20
  bitwise operations in python ? I am trying to determine whether the =
MSB of a=20
  byte is 0 or 1.</DIV>
  <DIV>&nbsp;</DIV>
  <DIV>Thanks,</DIV>
  <DIV>Praveen.</DIV></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_00A1_01C10480.32A6C600--