comp.lang.ada
 help / color / mirror / Atom feed
* newline in a simple program
@ 2007-12-18 12:28 Paul
  2007-12-18 12:48 ` petter_fryklund
                   ` (5 more replies)
  0 siblings, 6 replies; 11+ messages in thread
From: Paul @ 2007-12-18 12:28 UTC (permalink / raw)


Hi, given the following two simple programs


hello.adb
-----------------------
with ada.text_io;
procedure hello is
begin
ada.text_io.put("hello");
end hello;
-----------------------


hello.c
-----------------------
#include <stdio.h>
int main()
{
     printf("hello");
}
-----------------------

the result for the ada program is:
-----------------------
$ ./hello_in_ada
hello
$
-----------------------

and for the c program:
-----------------------
$ ./hello_in_c
hello$
-----------------------

The c program does not print a new-line, but the ada program does.

Is there any way to make the ada program not print a new-line?

And is this behavior part of the Ada standard or is it just part of gnat?

I looked for answers, but found none.

Thanks,

Paul Zacharzewski



^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2007-12-19 11:43 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-12-18 12:28 newline in a simple program Paul
2007-12-18 12:48 ` petter_fryklund
2007-12-18 13:11 ` Dmitry A. Kazakov
2007-12-18 13:45   ` petter_fryklund
2007-12-18 13:59     ` Dmitry A. Kazakov
2007-12-18 14:13 ` Brian Drummond
2007-12-18 14:49   ` petter_fryklund
2007-12-18 19:40     ` Jeffrey R. Carter
2007-12-18 16:44 ` Adam Beneschan
2007-12-19  4:35 ` anon
2007-12-19 11:43 ` Paul

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox