🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Jonathan Knight Wed, 02 Sep 1992 13:47
G++ 2.2.2 and floating point numbers
#1045
Author: Jonathan Knight
Date: Wed, 02 Sep 1992 13:47
25 lines
1006 bytes
G++ 2.2.2
Gas 1.38.1
ld 1.9
libg++ 2.2

I'm having trouble with this program:

#include <fstream.h>
#include <stdlib.h>

int main()
{       float a;

        cin >> a;
        cout << a << "\n";
}

The output is always 0 regardless of what I put in.


-- 
  ______    JANET :jonathan@uk.ac.keele.cs     Jonathan Knight,
    /       BITNET:jonathan%cs.kl.ac.uk@ukacrl Department of Computer Science
   / _   __ other :jonathan@cs.keele.ac.uk     University of Keele, Keele,
(_/ (_) / / UUCP  :...!uknet!kl-cs!jonathan    Staffordshire.  ST5 5BG.  U.K.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads