This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program unit1; | |
type | |
niz = array[1..100] of integer; | |
var | |
x: niz; | |
n, r, i: integer; | |
{ Hvala Tina! } | |
procedure unos (n:integer;var x: niz); | |
var i:integer; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program c; | |
var n, m, i: longint; | |
function brf(n: integer; b: boolean): integer; | |
begin | |
if b then brf := 1 | |
else brf := 0; | |
while(n > 0) do begin | |
if(b) then brf := brf * 10 | |
else brf := brf + 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program c; | |
var n, m, i: integer; | |
function brf(n: integer; b: boolean): integer; | |
begin | |
if b then brf := 1 | |
else brf := 0; | |
while(n > 0) do begin | |
if(b) then brf := brf * 10 | |
else brf := brf + 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--[[ Opens and closes the doors. | |
'id' is the indentifier, | |
starting from 0 as | |
the first one. | |
'status' "ture" or "false" | |
Defines should the door | |
be open --]] | |
function doorTrigger(id, status) | |
animation = "Open"; | |
if (status == false) then animation = "Close"; end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program z22; | |
var dan, mesec, godina: integer; | |
function prestupna(n: integer): boolean; | |
begin | |
prestupna := false; | |
if(((n mod 400) = 0)) or ( (not ((n mod 100) = 0)) and ((n mod 4)=0)) then begin | |
prestupna := true; | |
end; | |
end; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program game0; | |
{ VARIABLE,s } | |
const | |
buffer_size = 8; | |
type | |
c_string = Array [1..buffer_size] of char; | |
var | |
p0_name :c_string; | |
p0_type :char; {'w' warrior, 'r' ranger, 'm' mage} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program zN; { UBACI IME PROGRAMA OVDE } | |
var | |
g, p: real; {G: novac(gold), P: procenat} | |
begin | |
{ Pocetne vrednosti, nije neophodno } | |
g := 0; | |
p := 0; | |
{ Ucitaj podatke, prvo kolicinu novca pa procenat } | |
write('Pocetna kolicina novca: '); |
NewerOlder