Gangsters
The goal is to gather the gangsters with the maximal total prosperity in the restaurant by opening and closing the door appropriately. N gangsters are going to a restaurant. The i-th gangster comes at the time T_i and has the prosperity P_i. The door of the restaurant has K+1 states of openness expressed by the integers in the range [0, K]. The state of openness can change by one in one unit of time; i.e. it either opens by one, closes by one or remains the same. At the initial moment of time the door is closed (state 0). The i- th gangster enters the restaurant only if the door is opened specially for him, i.e. when the state of openness coincides with his stoutness S_i. If at the moment of time when the gangster comes to the restaurant the state of openness is not equal to his stoutness, then the gangster goes away and never returns.
The restaurant works in the interval of time [0, T].1
The goal is to gather the gangsters with the maximal total prosperity in the restaurant by opening and closing the door appropriately.
Input
The first line of the input contains the values N, K, T, the second - T_1, T_2, ..., T_N, the third - P_1, P_2, ..., P_N. The forth - S_1, S_2, ..., S_N. Numbers in rows are separated by spaces.
1 ≤ N ≤ 100; 1 ≤ K ≤ 100; 1 ≤ T ≤ 30 000; 0 ≤ T_i ≤ T; 1 ≤ P_i ≤ 300; 1 ≤ S_i ≤ K; All values in the input are integers.
Output
Print to the output the single integer - the maximal sum of prosperity of gangsters in the restaurant. In case when no gangster can enter the restaurant the output should be 0.