Created
November 2, 2015 08:48
-
-
Save yudium/432f7acca268a3e0aa61 to your computer and use it in GitHub Desktop.
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 variabel_scope; | |
{kamus utama} | |
var | |
A : Integer; | |
procedure tes(); | |
{kamus lokal} | |
var | |
A : Integer; | |
begin | |
A := 7; //variabel lokal, tidak akan menghapus nilai "10" dari variabel global karena mereka berdua berbeda | |
end; | |
begin | |
A := 10; // variabel glokal | |
tes(); | |
end. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment