If beginning is the index of the first char of inputexp that you want in the substring, and if length is the length of the substring, then
Code:
strncpy(label[j],inputexp+beginning,length);
label[j][length] = 0;
j++;