Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main(void) {
- char outer = 'c';
- for(int i=0; i<10; i++) {
- char inner = 'x';
- printf("%c", outer); // this works
- printf("%c", inner); // this also works
- }
- printf("%c", outer); // this works
- printf("%c", inner); // this doesn't work because inner is only valid between the { } in the for loop.
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement