#include <stdio.h>
#include "num.c"

int num1=10;

void increaseNumber(){
    //static붙이면 012
    int num=0;
    printf("%d\n", num);
    num++;
}

int main() {
    increaseNumber();
    increaseNumber();
    increaseNumber();

    printf("\n%d\n",num1);

    printf("%d\n",num);
    
    int a=10;
    int *pA=&a;

    printf("a의 크기 : %dbytes\n", (int)sizeof(a));
    printf("pA의 크기 : %dbytes\n", (int)sizeof(pA));
    
    printf("a의 값 : %d\n", a);
    printf("a의 주소 : %p\n", &a);

    printf("pA의 값 : %p\n\n", pA);



    int b=3;
    int *p=&a;

    printf("b의 주소 : %p\n", &b);

    printf("p의 값 : %p\n", p);








    
    return 0;
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: