I'm doing a program in C language, the problem is that I have a variable of type int and when I pass it as a parameter, C deletes it from me.
char letra, name[] = "";
int compuesto;
compuesto = Es_Compuesto(nom, lon);//RETORNA UN INT
if (compuesto != 0){
strncpy(name, nom, compuesto);//AQUI SE CAMBIA DE VALOR
if (strlen(name) != compuesto) {
name[compuesto] = 'char letra, name[] = "";
int compuesto;
compuesto = Es_Compuesto(nom, lon);//RETORNA UN INT
if (compuesto != 0){
strncpy(name, nom, compuesto);//AQUI SE CAMBIA DE VALOR
if (strlen(name) != compuesto) {
name[compuesto] = '%pre%';
}
}
';
}
}
They could tell me what is happening and how I could solve it. Thanks