Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

output with zero befor decimal point

Status
Not open for further replies.

jula

Technical User
Jul 9, 2010
2
Hi,
I've got a little problem. I need to write floting point numbers (f7.3-format?). The values are between -1.0 and 1.0 and I get always results as eg. -.345 or .345 but I need for further processing (CNC-code) the results like -0.345 or 0.345 with zero left of the dcimal point. I hope some body can help me.
jula
 
Which compiler are you using? Some compilers will give you .345, others will give you 0.345.

g95, IVF and lahey give 0.345.
 
Thank you xwb,
I think it is compiler problem. I use Microsoft Fortran Visual Workbench V 1.00. Realy old. I think I will have a look to the compilers you mentioned.
jula
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top