comp.lang.ada
 help / color / mirror / Atom feed
* After typing input of Integer it SKIPS getting the inputs of String.
@ 2015-07-11 15:14 Trish Cayetano
  2015-07-11 15:36 ` Niklas Holsti
  2015-07-11 18:05 ` Jeffrey R. Carter
  0 siblings, 2 replies; 3+ messages in thread
From: Trish Cayetano @ 2015-07-11 15:14 UTC (permalink / raw)


Code:
with ada.Text_IO; use ada.Text_IO;
with ada.Integer_Text_IO; use ada.Integer_Text_IO;
procedure Main is

    
   inputText: String (1..10);
   inputNmbr : Integer;
   StringNatural: Integer;  
begin
  
   Put_Line("Enter Integer");
   Get(inputNmbr,1);
   Put_Line("Enter String");
   Get_Line(inputText,StringNatural);
   Put_Line("===================");
   Put("Input for Integer: ");
   Put(inputNmbr,1);
   Put_Line("");
   Put_Line("Input for String: ");
   Put_Line(inputText(1..StringNatural));

end Main;

OUTPUT:

Enter Integer
2
Enter String
===================
Input for Integer: 2
Input for String: 


[2015-07-11 23:01:00] process terminated successfully, elapsed time: 00.86s

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

end of thread, other threads:[~2015-07-11 18:05 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-11 15:14 After typing input of Integer it SKIPS getting the inputs of String Trish Cayetano
2015-07-11 15:36 ` Niklas Holsti
2015-07-11 18:05 ` Jeffrey R. Carter

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