Bonjour à tous! Pouvez-vous m'éclaircir sur le message d'erreur suivant :
initials.c:25:11: error: expression result unused [-Werror,-Wunused-value]
for ( i, j; i < _long; i++) {
^
initials.c:25:14: error: expression result unused [-Werror,-Wunused-value]
for ( i, j; i < _long; i++) {
----------------------------------------------------------------------------------------------------------
Voici mon script :
Code:int main(void) { int _long = 0, i = 0, j = 0; char _name[] = "void", initials[] = "void"; strcpy(_name,GetString()); _long = strlen(_name); printf("%i\n", _long); for ( i, j; i < _long; i++) { if (_name[i] == ' ') { initials[j] = _name[i+1]; j += 1; } } printf("%s\n", initials); return 0; }
Merci!
-----