Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Fortran > Re: a cute prog...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 3 of 11 Topic 8150 of 8775
Post > Topic >>

Re: a cute program

by nospam@[EMAIL PROTECTED] (Richard Maine) Apr 18, 2008 at 12:44 AM

bru <bru@[EMAIL PROTECTED]
> wrote:

> robert.corbett@[EMAIL PROTECTED]
 wrote:
> > Consider the program
> > 
> >       SUBROUTINE SQRT
> >         PRINT *, 10
> >       END
> > 
> >       PROGRAM MAIN
> >         CALL SQRT
> >       END
> > 
> > This program is standard conforming.
> > 
> > Bob Corbett
> 
> Why 10 instead of '10' works?

Either would work fine, but that's clearly unrelated to Bob's point.

See the syntax of the PRINT statement in any Fortran text. The 10 here
is the output list. Lots of things are allowed in an output list, with
10 and '10' both being simple examples of literal constants (which in
turn are simple cases of expressions).

-- 
Richard Maine                    | Good judgement comes from experience;
email: last name at domain . net | experience comes from bad judgement.
domain: summertriangle           |  -- Mark Twain
 




 11 Posts in Topic:
a cute program
robert.corbett@[EMAIL PRO  2008-04-17 22:45:39 
Re: a cute program
bru <bru@[EMAIL PROTEC  2008-04-18 09:33:12 
Re: a cute program
nospam@[EMAIL PROTECTED]   2008-04-18 00:44:53 
Re: a cute program
glen herrmannsfeldt <g  2008-04-18 15:41:40 
Re: a cute program
nospam@[EMAIL PROTECTED]   2008-04-18 20:18:28 
Re: a cute program
robert.corbett@[EMAIL PRO  2008-04-18 18:31:18 
Re: a cute program
"Gerry Ford" &l  2008-04-20 02:05:13 
Re: a cute program
glen herrmannsfeldt <g  2008-04-20 01:25:52 
Re: a cute program
nospam@[EMAIL PROTECTED]   2008-04-20 09:05:53 
Re: a cute program
"Gerry Ford" &l  2008-04-21 00:59:04 
Re: a cute program
glen herrmannsfeldt <g  2008-04-21 00:44:47 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Oct 13 8:47:17 CDT 2008.