Reading floating point numbers

Allen Holtz vvcns at mars.lerc.nasa.gov
Sat Sep 22 02:03:43 AEST 1990


   I am trying to read floating point numbers from a file using the
following:

    fscanf(pointer,"%f",&arg);

The correct data is not being read.  Instead, totally random numbers are
read in.  Is there a certain way to read floating point numbers from a 
file.  All suggestions are welcome.

Thanks in advance,

Allen

--------------------------------------------------------------------------------
Allen Holtz                 
--------------------------------------------------------------------------------
Imagination is more important than knowledge.

                                   - Albert Einstein 
--------------------------------------------------------------------------------



More information about the Comp.lang.c mailing list