What is the meaning of _ after for in this code?
_
for
if tbh.bag: n = 0 for _ in tbh.bag.atom_set(): n += 1
It's just a variable name, and it's conventional in python to use _ for throwaway variables. It just indicates that the loop variable isn't actually used.