We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 50fbfd2 commit f3cf008Copy full SHA for f3cf008
a.out
0 Bytes
pointer-Arithmetic.c
@@ -1,11 +1,24 @@
1
// increment
2
+// #include <stdio.h>
3
+// int main(){
4
+// int age = 10;
5
+// int *ptr = &age;
6
+// printf("%u\n" ,ptr);
7
+// *ptr++ ;
8
9
+
10
+// return 0;
11
+// }
12
13
+// ============= . decrement
14
15
#include <stdio.h>
16
int main(){
- int age = 10;
- int *ptr = &age;
-printf("%u\n" ,ptr);
-*ptr++ ;
-printf("%u\n" ,*ptr);
17
+int age = 12;
18
+int *ptr = &age;
19
+printf("%u\n", ptr);
20
+*ptr--;
21
22
23
return 0;
24
}
0 commit comments