add pointer test
This commit is contained in:
parent
e91f44430d
commit
501065651d
1 changed files with 10 additions and 0 deletions
10
pointer.c
Normal file
10
pointer.c
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
#include<stdio.h>
|
||||
|
||||
int
|
||||
main() {
|
||||
float a[] = { 1.0, 2.0 };
|
||||
float* p = a;
|
||||
printf("size pointer %d", sizeof(p));
|
||||
printf("size float %d", sizeof(*p));
|
||||
printf("%f", *(++p));
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue