how can i add 2 numbers using delphi console application
and also windows application , compare both program ,
reply immediatly
Answer / faizulla khan
program Project1;
{$APPTYPE CONSOLE}
uses
SysUtils;
var
f1, f2: integer;
s: string;
begin
{ TODO -oUser -cConsole Main : Insert code here }
try;
f1:=0;
f2:=0;
write('Enter first integer: ');
readln(f1);
write('Enter second integer: ');
readln(f2);
writeLn('The numbers add up to '+inttostr(f1+f2));
writeLn('Press enter to quit');
except
on E : Exception do
writeln(E.Classname+' '+e.message);
end;
readln;
end.
| Is This Answer Correct ? | 18 Yes | 5 No |
what are the Current MSACCESS driver limitations ?
How to Retrieve a users login name ?
How to Disable close button of a window ?
How to Display a bitmap on the client area of an MDI parent form?
How to Call an IB stored procedure using TStoredProc?
How to create a transparent form?
How to add system menu items to a form ?
Specify a DefaultExpression for a TField object?
Can we write multi-user database applications in regular Delphi?
How to test if a given string contains a valid number?
How to make changes to the VCL code?
Explain the methods findfirst, findnext and findclose?