如果你使用二维数组或vector<int>w[105]的形式,请把第一维(就是象征k的那一维)开大像是这样:
vector<int>w[105]
int w[1005][1005]; vector<int> w[1005]