Article View: comp.std.unix
Article #1324How to convert a char into an int from 0 through 255?
From: brnstnd
Date: Sat, 06 Jan 1990 21:37
Date: Sat, 06 Jan 1990 21:37
10 lines
835 bytes
835 bytes
From: brnstnd@stealth.acf.nyu.edu The question is self-explanatory. This is a practical question as well as a theoretical one: I'd like a solution that is both conformant and portable in the real world. Does (int) (unsigned int) ch do the trick? What about (int) (unsigned char)? ---Dan Volume-Number: Volume 18, Number 8
Technical Details
Message-ID:
<498@longway.TIC.COM>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!longway!std-unixShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!longway!std-unix From: brnstnd@stealth.acf.nyu.edu Newsgroups: comp.std.unix,comp.std.c Subject: How to convert a char into an int from 0 through 255? Message-ID: <498@longway.TIC.COM> Date: 6 Jan 90 21:37:08 GMT Sender: std-unix@longway.TIC.COM Reply-To: uunet!stealth.acf.nyu.edu!brnstnd (Dan Bernstein) Followup-To: comp.std.unix Organization: IR Lines: 10 Approved: jsq@longway.tic.com (Moderator, John S. Quarterman)