Answered by : lorenzo-satta-chiris
var a: array[1..100] of integer;
Source : https://ksvi.mff.cuni.cz/~dingle/2017/pascal_reference.html | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
function name(argument(s): type1; argument(s): type2; ...): function_type;
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
Function Func_Name(params...) : Return_Value;
Procedure Proc_Name(params...);
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
type
Books = record title: packed array [1..50] of char; author: packed array [1..50] of char; subject: packed array [1..100] of char; book_id: integer;
end;
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
procedure name(argument(s): type1, argument(s): type 2, ... );
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
procedure findMin(x, y, z: integer; var m: integer);
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
Sr.No Control Statement & Description
1 break statement
Terminates the loop or case statement and transfers execution to the statement immediately following the loop or case statement.
2 continue statement
Causes the loop to skip the remainder of its body and immediately retest its condition prior to reiterating.
3 goto statement
Transfers control to the labeled statement. Though it is not advised to use goto statement in your program.
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
age: integer = 15;
taxrate: real = 0.5;
grade: char = 'A';
name: string = 'John Smith';
Source : https://www.tutorialspoint.com/pascal/pascal_quick_guide.htm | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
if condition then begin statement(s) end;
if condition then statement;
Source : https://en.wikibooks.org/wiki/Pascal_Programming/Cheatsheet | Last Update : Thu, 21 Jan 21
Answered by : lorenzo-satta-chiris
function add(x: integer; y: integer): integer; begin add := x + y; end;
Source : https://ksvi.mff.cuni.cz/~dingle/2017/pascal_reference.html | Last Update : Thu, 21 Jan 21