I think you are confused about what any means. It is used to check a sequence of values, and see if any of them is "true". That's not related to finding out if a value is "any number" or "any of these possibilities".
If you have a fixed, finite set of possibilities that you want to consider, then what you really want to know is whether your candidate value is in that set:
x in {1, 2, 3, 4, "hi mom"} # returns whether x is any of those values
But "any number" is not a finite set. First off, you need to define what you mean by number; and then you need to perform the appropriate test. It sounds like what you are trying to do is check whether the value is an integer. In other words, you are concerned with the type of the values in the list.
If you already know they're all integers, then there's nothing to test; if you don't care what the value is, then just don't consider it when you make your checks. But if you need to be sure it's an integer, then the way to do that is
isinstance(x, int) # returns whether x is an `int`
But maybe you have confused me, by giving an example "to-search list" that happens to be the same length as your "pattern", when you actually want to look for the pattern at any point in a longer list.
In that case, you can make a function that does an exact match of the pattern against a list of the same length; and then use any to check whether any pattern-lengthed sublist matches. any is designed to be used with generator expressions, and it looks like this:
def match(a_sublist, the_pattern):
# put your logic here
def search(the_full_list, the_pattern):
pattern_length, full_length = len(the_pattern), len(the_full_list)
return any(
match(the_full_list[i:i+pattern_length], the_pattern)
for i in range(full_length - pattern_length)
)
There are more efficient ways to match, depending on the details of your pattern, that will be inspired by string search algorithms and regular expression engines. But that is getting into much more difficult material - the above should get you started.