logical reason behind this can be explained with an example of another c program.Becasue when unary operators come into action it uses a concept called stack and reverse order execution.
#include<stdio.h>
void main()
{
int num=0;
printf("%d%d%d%d",num++,++num,num++,++num);
getch();
}
you make think that output of the program might be num++,++num,num++,++num executed in this way.you will execute from left to right.
According to your approach answer is 0224.
But c will execute in reverse order from right to left ++num,num++,++num, num++ and now you think answer is 1133.But it is not since it will put it in stack and take it in reverse order so the
correct answer is 3311
Hope this might answer your queries
Correct me if i am wrong.
Visit my blog here:<a href="https://novicetoprogramming.blogspot.com/" target="_blank" rel="nofollow noopener noreferrer">Virtual Helper</a>