Problem A Arrays and Strings (cont.)
This and the next question walk you through more exercises on manipulating arrays and strings. Arrays are so important in C that we will deal with them throughout the C part of the course. Download lab3.c. This short program uses an array of size 12 to store input strings read in using scanf, and simply outputs the array elements (char and its index) after each read (similar to the last part of lab2D.c of lab2).
First observe the initial values of the array. Arrays without explicit initializer get random values. Run it again and you might see the change of the strange values. This implies that when you manually store characters into a char array to create a string, dont assume that the uninitialized array was filled with s. You need to manually add a after the last stored character.
| h | e | o | w | o | r | d |

![[Solved] EECS2031 Lab3-Arrays and Strings, Relational and Logic operators, Type conversion, Bitwise operations](https://assignmentchef.com/wp-content/uploads/2022/08/downloadzip.jpg)
