Newbie asks(2): How to do this line of C in Py?

William Park opengeometry at yahoo.ca
Wed Jul 11 17:31:49 CEST 2001


On Wed, Jul 11, 2001 at 01:50:52AM +0800, Steve S.L. Wong wrote:
> if sscanf(command,"%c%d",&c,&d) != 2 {
> }

- isolate the char/number, by cutting at the delimiter(s).  See,
  'string.split()' 
- convert ASCII characters into proper char/integer type.  See 'int()'.

-- 
William Park, Open Geometry Consulting, <opengeometry at yahoo.ca>
8 CPUs cluster, (Slackware) Linux, Python, LaTeX, Vim, Mutt, Sc.




More information about the Python-list mailing list