struct

Discussion in 'Python' started by Back9, May 19, 2010.

  1. Back9

    Back9 Guest

    Can anyone explain the difference between f and d in struct unpack?
    When using them, some data work in either one not both.
    To me it seems to be same,

    TIA
     
    Back9, May 19, 2010
    #1
    1. Advertising

  2. Back9

    Gary Herron Guest

    On 05/19/2010 02:53 PM, Back9 wrote:
    > Can anyone explain the difference between f and d in struct unpack?
    > When using them, some data work in either one not both.
    > To me it seems to be same,
    >
    > TIA
    >


    'f' is single precision float (32 bits), and
    'd' is a double precision float (64 bits)

    Gary Herron
     
    Gary Herron, May 19, 2010
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. RA Scheltema
    Replies:
    3
    Views:
    404
    RA Scheltema
    Jan 6, 2004
  2. Gunnar G

    struct in struct

    Gunnar G, May 31, 2004, in forum: C++
    Replies:
    14
    Views:
    806
  3. DanielEKFA
    Replies:
    8
    Views:
    615
    DanielEKFA
    May 16, 2005
  4. James Harris
    Replies:
    4
    Views:
    1,396
    James Harris
    Oct 9, 2003
  5. Chris Fogelklou
    Replies:
    36
    Views:
    1,391
    Chris Fogelklou
    Apr 20, 2004
Loading...

Share This Page