regex - Python - Subtracting a List with strings of a List with Regexes -


i have 2 lists, 1 full of regexes , other full of strings. have check if list strings complete, regex list "complete". want subtract regexes match strings , print leftovers.

list regexes:

["ntp server x.x.x.x", "ntp server x.x.x.x", "ntp server x.x.x.x","logging x.x.x.x",  "snmp-server community xxxx ro " + regex_string_with_digits_and_special_marks,             {"snmp": ["(access-list " + regex_string_with_digits_and_special_marks + " permit x.x.x.x)",           "(access-list " + regex_string_with_digits_and_special_marks + " permit x.x.x.x)",           "(access-list " + regex_string_with_digits_and_special_marks + " permit x.x.x.x)",           "(access-list " + regex_string_with_digits_and_special_marks + " deny\s+any)",           "(access-list " + regex_string_with_digits_and_special_marks + " remark .+)"],  "vty": ["(access-list " + regex_string_with_digits_and_special_marks + " permit x.x.x.x)",          "(access-list " + regex_string_with_digits_and_special_marks + " deny\s+any)",          "(access-list " + regex_string_with_digits_and_special_marks + " remark .+)"]}] 

list strings:

[{'vty': []},  {'snmp': ['access-list 2 remark *** snmp ***',            'access-list 2 permit x.x.x.x',            'access-list 2 permit x.x.x.x',            'access-list 2 permit x.x.x.x',            'access-list 2 deny   any']},  'snmp-server community xxxx ro 2'] 

is there way?


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -