I am java programmer ,but now i starting to learn more abut pascal programming could you help please How to write this java syntax in pascal
A[m] = scan.nextInt();
program is that asking the user to input the "size" then input the element... (using Array) I have done this :
writeln('How many Number you would like to sort:');
readln(size);
For m := 1 to size do
Begin
if m=1 then
begin
writeln('');
writeln('Input the first value: ');
(????)
End;
I didn't know how to complete it ?
java syntax is:
for( m = 0; m<size; m++)
{
if(m == 0)
{
System.out.println("");
System.out.print("^_^ Input The First Value:");
A[m] = scan.nextInt();
}
else if(m == size -1)
{
System.out.print("^_^ Input The Last Value:");
A[m] = scan.nextInt();
}
else
{
System.out.print("^_^ Input The Next Value:");
A[m]= scan.nextInt();
}
}
thank you