Last active
November 9, 2016 11:07
-
-
Save madgen/8ffb7e810614b7db351852d07486d134 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main() { | |
char *cptrs[6] = { "hello", "mellow", "yellow" }; | |
char **cptrs2; | |
void **vptrs = (void**) cptrs; | |
vptrs++; | |
cptrs2 = (char**) vptrs; | |
printf("%s\n", *cptrs2); // Prints mellow | |
vptrs++; | |
cptrs2 = (char**) vptrs; | |
printf("%s\n", *cptrs2); // Prints yellow | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment