0 votes 0 votes is *ptr=&a is true in C i found this in can anyone explain what does *ptr = &i; in the above picture Programming in C programming output programming-in-c + – shiva0 asked Jan 14, 2019 shiva0 851 views answer comment Share Follow See all 5 Comments See all 5 5 Comments reply Show 2 previous comments Satbir commented Jan 14, 2019 reply Follow Share 1st and 2nd line are different things. I think you are getting confused in it. ------------------------------------------------------------------------------------------------------------------------------------------------------------------ int *ptr =&i; // we are creating the pointer and initiailizing it to point to address of i. here *ptr means than ptr is pointer variable. it can also be written as int *ptr; ptr =&i; //pointer points to location where value of i is stored ---------------------------------------------------------------------------------------------------------------------------------------------------------------- *ptr =&i; // we are storing the address of i as a value in the address location pointed by pointer. here *ptr is denoting the value present in the location where pointer ptr is pointing. ---------------------------------------------------------------------------------------------------------------------------------------------------------------- *ptr = i; // value contained in the address location pointed by pointer becomes i. 0 votes 0 votes prashant jha 1 commented Jan 14, 2019 reply Follow Share int *ptr = &a and ptr = &a will do the same job. *ptr= &a will not do the same job. 0 votes 0 votes shiva0 commented Jan 14, 2019 reply Follow Share thank you...! 0 votes 0 votes Please log in or register to add a comment.