hello this its me again. im having trouble using the if function in a linked list. so basically i wanted to count how many nodes contains a character as its element in a linked list. basically it has 5 nodes and all of them has a char element. this is what i had come up with and i am stuck because it seems that the statement for total is not being executed.
the output for total is 0, instead of 5. pls anyone can help me?
struct list *next;
struct list *p;
struct list *rec_ptr;
printf("The elements are:\n");
printf("\nTotal Nodes with Character Elements is %d",total);