// // return_pointer.c // // // Created by Bibhas Ghoshal on 20/02/21. // #include short *days_in_months(void); int main() { short i,*ptx; ptx = days_in_months(); ++ptx; for (i=1; i<6; i++) { printf("Months%hd:%hd\n",i,*ptx++); // ++ has higher precedence than * } return 0; } short *days_in_months(void) { static short month[] = {0,31,28,31,30,31,30,31,31,30,31,30,31}; return month; }