# even divisible by number of weeks in a month

#### Fahsid1230

##### Active Member
Hi Folks,
I have this unique situation and hoping someone will be able to help me.
on row1 (b/w col B to J) I have:
7/6/2008;07/13/08;07/20/08;07/27/08;08/03/08;08/10/08;08/17/08;08/24/08;08/31/08
now if I have a number in row 2 which is just associated to the month of July. That # is 169. How can I write a formula or is there a way to divide this # and solve two problems:
1) it should be divisible by 4 as you can see there are only four weeks, so it spread out just under July and it should be evenly spread as much as possible without any decimals.
So for example if it can be spread as (under July):
42; 42; 42; 43
and if there is number falls under the month which has five weeks, it should be evenly divided by 5 but in a way that I just have a whole number and no decimal.
Any help will be appreciated.
Thanks

### Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".

#### jimrward

##### Well-known Member
without applying logic for calculating whether it is a 4 or 5 week month one solution would be as follows

assume your number is in B2 then

for a 4 week month, lets put the values in C1, C2, C3, C4,

C1 = INT(\$B\$2/4)
C2 = INT(\$B\$2/4)
C3 = INT(\$B\$2/4)
C4 = \$B\$2 - SUM(C1:C3)

for a 5 week month, you would divide by 5

C1 = INT(\$B\$2/5)
C2 = INT(\$B\$2/5)
C3 = INT(\$B\$2/5)
C4 = INT(\$B\$2/5)
C5 = \$B\$2 - SUM(C1:C4)

Replies
2
Views
352
Replies
1
Views
278
Replies
0
Views
200
Replies
2
Views
224
Replies
4
Views
437

1,191,177
Messages
5,985,140
Members
439,942
Latest member
bkexcel11230

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back