Revert "Trying and failing to break ex11.c"
This reverts commit 52a5ea57e1
.
This commit is contained in:
parent
52a5ea57e1
commit
8af4f619f4
10
lcthw/ex11.c
10
lcthw/ex11.c
@ -3,21 +3,15 @@
|
|||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
int numbers[4] = { 0 };
|
int numbers[4] = { 0 };
|
||||||
char name[4] = { 'a', 'a', 'a', 'a' };
|
char name[4] = { 'a' };
|
||||||
|
|
||||||
// first, print them out raw
|
// first, print them out raw
|
||||||
printf("numbers: %d %d %d %d\n",
|
printf("numbers: %d %d %d %d\n",
|
||||||
numbers[0], numbers[1], numbers[2], numbers[3]);
|
numbers[0], numbers[1], numbers[2], numbers[3]);
|
||||||
|
|
||||||
printf("numbers: %c %c %c %c\n",
|
|
||||||
numbers[0], numbers[1], numbers[2], numbers[3]);
|
|
||||||
|
|
||||||
printf("name each: %c %c %c %c\n",
|
printf("name each: %c %c %c %c\n",
|
||||||
name[0], name[1], name[2], name[3]);
|
name[0], name[1], name[2], name[3]);
|
||||||
|
|
||||||
printf("name each: %d %d %d %d\n",
|
|
||||||
name[0], name[1], name[2], name[3]);
|
|
||||||
|
|
||||||
printf("name: %s\n", name);
|
printf("name: %s\n", name);
|
||||||
|
|
||||||
// setup the numbers
|
// setup the numbers
|
||||||
@ -30,7 +24,7 @@ int main(int argc, char *argv[])
|
|||||||
name[0] = 'Z';
|
name[0] = 'Z';
|
||||||
name[1] = 'e';
|
name[1] = 'e';
|
||||||
name[2] = 'd';
|
name[2] = 'd';
|
||||||
name[3] = 'A';
|
name[3] = '\0';
|
||||||
|
|
||||||
// then print them out initialized
|
// then print them out initialized
|
||||||
printf("numbers: %d %d %d %d\n",
|
printf("numbers: %d %d %d %d\n",
|
||||||
|
Loading…
Reference in New Issue
Block a user