home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.fortran
- Path: sparky!uunet!gumby!wupost!cs.uiuc.edu!sparc0b!ctaylor
- From: ctaylor@cs.uiuc.edu (Conrad W Taylor)
- Subject: Print characters on one line without newline...???
- Message-ID: <BxtnK6.23s@cs.uiuc.edu>
- Sender: news@cs.uiuc.edu
- Organization: University of Illinois at Urbana-Champaign
- Date: Mon, 16 Nov 1992 18:33:42 GMT
- Lines: 35
-
- I'm writting this PrintX routine that is to print
- the letter X n times on one line without any spaces and
- newline. My PrintX routine looks like this:
-
- SUBROUTINE PrintX(XCOUNT)
- INTEGER XCOUNT
-
- INTEGER i
-
- DO 10 i, XCOUNT
- PRINT 20
- 10 CONTINUE
- 20 FORMAT(1X, 'X')
-
- PRINT *
-
- RETURN
- END
-
- correct: XXXXX...X
- incorrect: X
- X
- X
- .
- .
- X
-
- This routine only prints one 'X' on n lines and I want it to print
- n X's on one line without any spaces in between and without a new-
- line character. Could someone explain what I might be doing wrong?
- Thanks in advance to all that reply to this e-mail.
-
- -Conrad
-
-
-