#include <stdio.h>
void f(int *g, int a) {//戻り値なし
*g = a;
}
int add(int g, int a) {//戻り値あり
return g + a;
}
int main() {
int k[10];
f(&k[1], 2);
printf("%d",k[1]);
puts(" ");
k[2] = add(k[1],2);
printf("%d",k[2]);
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: