Related to “varvarname” is the desire of some beginners to use several different arrays with synchronised content, so the same index at every array will contain a different piece of data for the same record:
# Bad code char * names[ITEMS_COUNT]; char * addresses[ITEMS_COUNT]; int ages[ITEMS_COUNT]; char * phone_numbers[ITEMS_COUNT]; . . . names[num] = strdup("Isaac Newton"); addresses[num] = strdup("10 Downing St."); ages[num] = 25; phone_numbers[num] = strdup("123456789");
These arrays will become hard to synchronise, and this is error prone. A better idea would be to use an array (or a different data structure) of structs, classes, or pointers to them:
Person * people[ITEMS_COUNT]; num = 0; people[num++] = create_person( "Isaac Newton", "10 Downing St.", 25, "123456789" );