0 votes 0 votes $\text{prtdata}$ is a pointer to a data type. The expression $^*\text{prtdata}++$ is evaluated as (in C++) $^*(\text{prtdata++})$ $(^*\text{prtdata})++$ $^*(\text{prtdata})++$ Depends on compiler Unknown Category ugcnetcse-nov2017-paper2 + – Arjun asked Nov 5, 2017 edited Jul 12, 2020 by go_editor Arjun 778 views answer comment Share Follow See 1 comment See all 1 1 comment reply santhoshdevulapally commented Nov 9, 2017 reply Follow Share Post increment is higher priority than dereference operator. So it evaluated as *(ptrdata++). it should be option 1. 0 votes 0 votes Please log in or register to add a comment.
1 votes 1 votes Post-increment (++) has higher precedence than dereference (*). Hence it increments the address that the pointer holds, then dereferences it answer will be *(ptrdata++) sh!va answered Nov 6, 2017 sh!va comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes ++ and * are unary operators and they have same precedence. The order of evaluation is judged by associativity. They have right to left associativity so ptrdata ++ is evaluated first then * is applied. Ans is 1)*(ptrdata++) gari answered Nov 11, 2017 gari comment Share Follow See all 0 reply Please log in or register to add a comment.