🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.misc
Article #1253

Re: Lessons from Algol (Was: JLG's flogging of horses)

#1253
From: Tony Warnock
Date: Thu, 03 May 1990 19:59
18 lines
949 bytes

With respect to the C statement:
 
     printf("The answer is %d, not %d\n", ans, resp)
 
one can use the following Fortran statement
 
     write(*,*)' The answer is',ans,' not',resp
 
which seems as simple as the C version. The suggested
 
       WRITE (BUFFER,100) PRINTLENGTH(ANS),PRINTLENGTH(RESP)
  100  FORMAT('(;;The answer is '',',I1,','',not '',',I1,;I;;)')
       WRITE(5,BUFFER)ANS,RESP
 
seems to be somewhat verbose. ( Of couse my suggestion could be
in upper case if desired. )
Technical Details
Message-ID: <14357@lambda.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cs.utexas.edu!yale!cmcl2!lanl!lambda!ttw
References: <1990Apr19.180903.27750@maths.nott.ac.uk> <4277@tukki.jyu.fi> <N+63FGBggpc2@ficc.uu.net>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cs.utexas.edu!yale!cmcl2!lanl!lambda!ttw
From: ttw@lambda.UUCP (Tony Warnock)
Newsgroups: comp.lang.misc
Subject: Re: Lessons from Algol (Was: JLG's flogging of horses)
Summary: Re Fortran and C I/O
Message-ID: <14357@lambda.UUCP>
Date: 3 May 90 19:59:04 GMT
References: <1990Apr19.180903.27750@maths.nott.ac.uk> <4277@tukki.jyu.fi> <N+63FGBggpc2@ficc.uu.net>
Lines: 18