prova cosi
codice:char *str="aabbcd"; char *cod1=new char[2]; char *cod2=new char[2]; char *lenID=new char[1]; char *lenOP=new char[1]; strncpy(cod1,str,2); strncpy(cod2,str+2,2); strncpy(lenID,str+4,1); strncpy(lenOP,str+5,1);
prova cosi
codice:char *str="aabbcd"; char *cod1=new char[2]; char *cod2=new char[2]; char *lenID=new char[1]; char *lenOP=new char[1]; strncpy(cod1,str,2); strncpy(cod2,str+2,2); strncpy(lenID,str+4,1); strncpy(lenOP,str+5,1);