Can iron pills be taken with vitamin b12?

Yes. I wish they were all this easy to answer. Vegetarians in particular do well to supplement with both of these.