Your problem is that in arithmetic computation like this:
A is B
everything on the right side (B) has to be already known. No variables there.
You may do something like this:
not_number(X, Y) :- not_number(X, Y, 0).
not_number([], Y, Y).
not_number([H|T], Y, Z) :-
\+ (number(H)),
Z1 is Z+1,
not_number(T, Y, Z1).
not_number([H|T], Y, Z) :-
number(H),
not_number(T, Y, Z).
(tested this code now, it works).
Now the third argument is an accumulator. It counts how many not-numbers there are. When the list is empty, this third argument is unified with the second one and it becomes the proper answer.
Prolog, when given the chance, will go through all the routes possible. If you do something like this:
cat(adam).
cat(eve).
and then ask:
?- cat(X).
You could get both answers: X = adam and X = eve.
It applies to your code too: notice that when the head of the list is not a number, you can still do this:
not_number([_|Tail],Result):-
not_number(Tail,Result).
which gives not the answer you would like. You have to cut off the routes that don't interest you. In this case, I would add
number(Head).
to ensure that we skip an element in a list without increasing the counter by 1 only when this element is not a number.
To enforce Prolog to find some other results, you must press ";" on your keyboard (like in this adam and eve example).