//============================================================== // Deklaracja zmiennej globalnej kategorii 'extern';
// Plik podstawowy projektu; //
// ver data temat autor // 100 2010/11/14 Pierwszy projekt J.Malinowski // 101 2015/10/03 Cleanup JM // 102 2019/12/16 Cleanup JM //============================================================== #include <stdio.h> #include <conio.h> //---#include "funkcje.h" double glx; //---int main() { //??? register int x1 = 5, y1 = 9; glx = 5.5; double glx = 3.3;
printf("Global variable - before calling the function: %lf\n", ::glx);
printf("Local variable - before calling the function: %lf\n", glx);
Global_Demo();
printf("Global variable - after calling the function: %lf\n", ::glx);
printf("Local variable - after calling the function: %lf\n", glx);
printf("\nPress any key to terminate program\n"); getch();
return 0; }