Question: Does nail biting and swallowing it invalidate fasting?
Answer: Yes, but there is no kaffaarah. Beware that swallowing it even when not fasting is forbidden and sinful.
Question: In my class there are girls, does working with them and looking at them invalidate fasting?
Answer: No.
... and Allah knows best.