2007 Buick Lucerne - Cuts off

while driving, my car cuts off on me, and also while stopped at a traffic light

Is the check engine light on?