What am I doing wrong? I thought in both cases some elements of "Phrase" would be printed back, but not so. Trying to dereference the element, but get unwanted characters.
8:27: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
10:26: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
9:21: warning: 'array[4]' is used uninitialized in this function [-Wuninitialized]
11:15: warning: 'argv[3]' is used uninitialized in this function [-Wuninitialized]
Note that the subscript operator has higher precedence than the dereference operator so *array[4] will be evaluated as *(array[4]). If you want to access the fifth character of the first element you need use parentheses like this: (*array)[4]
some other memory location that has unknown bytes. You can grab a pointer to memory outside of your legit data and if it does not crash, printing it will give you random junk. You can play with it to see...