Newline Suppression in Print 
Author Message
 Newline Suppression in Print


Quote:

> <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
> <html>
> Hello,
> <p>&nbsp;&nbsp; What is the character sequence that you can use at the
> end of the
> <br>arguments to "print" so that the following "print" statement
> concatenates
> to
> <br>the output of the first without the insertion of a newline?
> <p>Thanks!
> <br>Phill.
> <br>&nbsp;</html>

Just use printf instead of print.
Not to nitpick, but I'd also consider not posting with HTML too >:)
Ha!!
--
In science, there is only physics; all the rest is stamp collecting.  
  -Ernest Rutherford.

ICQ 111257732



Tue, 30 Dec 2003 09:07:22 GMT  
 Newline Suppression in Print
Thanks for your suggestion!  I was just trying to remember the character
or character-sequence - at this point I guess it is trivia.
I didn't realize that my message was going out in html - this was the
first I have sent.  Hopefully I have fixed the problem.
Phill.
Quote:



> > <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
> > <html>
> > Hello,
> > <p>&nbsp;&nbsp; What is the character sequence that you can use at the
> > end of the
> > <br>arguments to "print" so that the following "print" statement
> > concatenates
> > to
> > <br>the output of the first without the insertion of a newline?
> > <p>Thanks!
> > <br>Phill.
> > <br>&nbsp;</html>

> Just use printf instead of print.
> Not to nitpick, but I'd also consider not posting with HTML too >:)
> Ha!!
> --
> In science, there is only physics; all the rest is stamp collecting.
>   -Ernest Rutherford.

> ICQ 111257732



Wed, 31 Dec 2003 13:23:09 GMT  
 Newline Suppression in Print

Quote:
> Thanks for your suggestion! I was just trying to remember the character
> or character-sequence - at this point I guess it is trivia.

Do this:

    { printf("%s", $0) }

Do NOT do this:

    { printf($0) }

Quote:
> I didn't realize that my message was going out in html - this was the
> first I have sent. Hopefully I have fixed the problem.

You fixed the HTML problem. Now fix the Jeopardy(TM)-style quoting
problem. ;-)

--
Jim Monty

Tempe, Arizona USA

Quote:



> > > <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
> > > <html>
> > > Hello,
> > > <p>&nbsp;&nbsp; What is the character sequence that you can use at the
> > > end of the
> > > <br>arguments to "print" so that the following "print" statement
> > > concatenates
> > > to
> > > <br>the output of the first without the insertion of a newline?
> > > <p>Thanks!
> > > <br>Phill.
> > > <br>&nbsp;</html>

> > Just use printf instead of print.
> > Not to nitpick, but I'd also consider not posting with HTML too >:)
> > Ha!!



Wed, 31 Dec 2003 14:58:51 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. PEP 259: Omit printing newline after newline

2. PEP 259: Omit printing newline after newline

3. instead of single column, print fields 3 or 4 across then newline

4. Printing newlines

5. echo, print and the newline character

6. Q: print and newline

7. print without newline?

8. print without newline

9. Printing without newlines..

10. Print characters on one line without newline...???

11. Winnt and Rexx output Suppression

12. Corruption in Ada9x office - suppression of Ada survey results

 

 
Powered by phpBB® Forum Software