I think I'm getting the hang of pointer basics with my textbook. I've read the chapter a couple times now and it's starting to make sense
A few lingering questions from the exercises I completed
First set (regarding picture directly below):
Question i. : Are a). and g). indeed the only aliases for i? (I looked these up in an answer key that I'm not 100% sure is correct)
Question 1. : Outside of function calls, when would you apply the & (address extraction) operator for an object that is not pointing to anything such as i? An example I can think of from the book (it was a one sentence allusion) printing an address number with the %p conversion spec in a format string.
Same question in regard to the * (de-referencing) operator Example I can think of are printing the value of an object like this with printf. (Again, this was covered in about one sentence in the book)
Question 2. : What is the different between g). *&i and h). &*i. Shouldn't the two operators cancel out since they are like the inverse of one another? And why is g). considered an alias, while h). is not?
----------------------------------------------------
Second set (just one quick question)
Question 3: Is my explanation of why b). is illegal correct? I found this one tricky at first but then looked at the text and examples under the orange text.