* Re: jumping a loop
1998-02-05 0:00 jumping a loop marc
@ 1998-02-05 0:00 ` Jean-Pierre Rosen
0 siblings, 0 replies; 2+ messages in thread
From: Jean-Pierre Rosen @ 1998-02-05 0:00 UTC (permalink / raw)
marc a écrit dans le message <34D91382.6FC1@er.uqam.ca>...
>jj091849@er.uqam.ca
>I have writen the followinf (simple!!)program.
>at the beginning it's jumping a loop.
>compile and run and the first item is jump!
>Could you help me with this .
>thanK's (compiled with object ada7.1)
>-------------------------------------------------
>
> with text_io; use text_io;
>procedure essai is
[...]
> text_io.put("Combiens de items à entrez (0-10)");
> Es_Entiers.get(item=> iter);
Add a call to Skip_Line here.
Integer_IO leaves you before the end of line, so when you read a string you will get an empty string.
And BTW, do you know that there is a french speaking version of comp.lang.ada ? It's called fr.comp.lang.ada
^ permalink raw reply [flat|nested] 2+ messages in thread
* jumping a loop
@ 1998-02-05 0:00 marc
1998-02-05 0:00 ` Jean-Pierre Rosen
0 siblings, 1 reply; 2+ messages in thread
From: marc @ 1998-02-05 0:00 UTC (permalink / raw)
jj091849@er.uqam.ca
I have writen the followinf (simple!!)program.
at the beginning it's jumping a loop.
compile and run and the first item is jump!
Could you help me with this .
thanK's (compiled with object ada7.1)
-------------------------------------------------
with text_io; use text_io;
procedure essai is
PACKAGE ES_Entiers IS NEW Text_io.Integer_IO(Num=> Integer);
TYPE File_Mode IS (In_File,Out_File);
lki,auteur,source,ref,idn:string(1..32);
type t_item is record
item :string(1..32);
an,mois,jour,heure,min :NATURAL:=0;
end record;
v_item: Array(1..10) of t_item;
iter,long,i:natural:=0;
begin
text_io.put("Combiens de items � entrez (0-10)");
Es_Entiers.get(item=> iter);
for i In 1..Iter loop
text_io.put(item=>"item : ");
get_line(v_item(i).item,last=>long);
text_io.New_Line(2);
long:=0;
end loop;
end essai ;
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1998-02-05 0:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-02-05 0:00 jumping a loop marc
1998-02-05 0:00 ` Jean-Pierre Rosen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox