Assertion: problem's solution | /r/HasProperty | 5 6
Facets:
Source sentences:
text: 1 Weighted - Activity - Selection ( S ) : // S = list of activities 2 3 sort S by finish time 4 opt [ 0 ] = 0 // opt[j] represents optimal solution (sum of weights of selected activities) for S[1,2..,j] 5 6 for i = 1 to n : 7 t = binary search to find activity with finish time <= start time for i 8 // if there are more than one such activities, choose the one with last finish time 9 opt [ i ] = MAX ( opt [ i - 1 ], opt [ t ]