*ptr++ and ++*ptr both * and ++ have same precedence but due to associativity of operators from right to left both can be written as
*(ptr++) and ++(*ptr) so
*ptr++ => *(ptr++) => First it wil change its pointing value(address) that is,ptr will point to next value(address) just after old value and then derefence to get value.
++*ptr => ++(*ptr) => it will increment the value pointed by ptr.