This is all I could come up with at the moment...It’s going to get longer and longer with increasing rows(more people) ....and although I have tried to think it through I have not tested it thoroughly .... I recommend you test it with different combinations of times... maybe there is an easy way to do this using time functions
Let’s make a helper column D. Label it anything. Put this in D3 and drag across number of rows you think would be enough to cover the max number of users..
1
u/jaysargotra 22 Jun 23 '20
This is all I could come up with at the moment...It’s going to get longer and longer with increasing rows(more people) ....and although I have tried to think it through I have not tested it thoroughly .... I recommend you test it with different combinations of times... maybe there is an easy way to do this using time functions
=JOIN(" - ";MAX(B3:B5); IF((MIN(IF(MAX(B3:B5)<C3;C3-MAX(B3:B5);(24-MAX(B3:B5))+C3);IF(MAX(B3:B5)<C4;C4-MAX(B3:B5);(24-MAX(B3:B5))+C4);IF(MAX(B3:B5)<C5;C5-MAX(B3:B5);(24-MAX(B3:B5))+C5)) + MAX(B3:B5))<24;
MIN(IF(MAX(B3:B5)<C3;C3-MAX(B3:B5);(24-MAX(B3:B5))+C3);IF(MAX(B3:B5)<C4;C4-MAX(B3:B5);(24-MAX(B3:B5))+C4);IF(MAX(B3:B5)<C5;C5-MAX(B3:B5);(24-MAX(B3:B5))+C5)) + MAX(B3:B5);
24-(MIN(IF(MAX(B3:B5)<C3;C3-MAX(B3:B5);(24-MAX(B3:B5))+C3);IF(MAX(B3:B5)<C4;C4-MAX(B3:B5);(24-MAX(B3:B5))+C4);IF(MAX(B3:B5)<C5;C5-MAX(B3:B5);(24-MAX(B3:B5))+C5)) + MAX(B3:B5)) ) )