romesaz
100+ Head-Fier
- Joined
- Oct 31, 2004
- Posts
- 308
- Likes
- 10
hey, I know there's at least a few software developers here, so I thought i'd ask.
How can you type cast in Python?
mainly, casting a string to a float.
and how would you deal with any fractionals?
i.e. given a = '5.5'
just doing int(a) doesn't exactly work well
Thanks!
How can you type cast in Python?
mainly, casting a string to a float.
and how would you deal with any fractionals?
i.e. given a = '5.5'
just doing int(a) doesn't exactly work well
![biggrin.gif](http://www.head-fi.org/forums/images/smilies/http://hfimage.head-fi.org/smilies/biggrin.gif)
Thanks!