Looked through the other questions involving the same error but don't quite understand why I'm getting the error.

I'm trying to assign an equation to a variable within a function of the same name?

I'm new to this so if anyone could explain to me why this is happening that would be awesome.

The fifth line from the bottom is where I'm getting the error

```
#define DAYS_PER_WEEK 7

#define THURSDAY 0
#define FRIDAY   1
#define SATURDAY 2
#define SUNDAY   3
#define MONDAY   4
#define TUESDAY  5
#define WEDNESDAY 6

#define TRUE 1
#define FALSE 0
#define DAYS_PER_WEEK 7

int dayOfWeek (int doomsday, int leapYear, int month, int day);

int main (int argc, char *argv[]) {

   dayOfWeek(SUNDAY, FALSE, 1, 10);

   return EXIT_SUCCESS;
}

int dayOfWeek (int doomsday, int leapYear, int month, int day) {
   if (month == 1) {
      int doomsDate = 4;
      dayOfWeek = (day + doomsDate)/DAYS_PER_WEEK);
      printf ("The day of the week is: =%d\n",dayOfWeek);
   }
   return dayOfWeek;
 }

```

So after @Gopi explained why I changed the function to this

```
int dayOfWeek (int doomsday, int leapYear, int month, int day) {
   if (month == 1) {
      int doomsDate = 4;
      int dayNum = (day + doomsDate)/DAYS_PER_WEEK;
      printf ("The day of the week is: =%d\n",dayNum);
   }
   return dayOfWeek;
}

```

I need to satisfy the following assert: 

```
assert (dayOfWeek (SUNDAY, FALSE, 1, 10) == SATURDAY); 

```

how would I go about doing that...