Which answer best corrects the sentence fragment?

He ate a snack. While studying at his desk.


With a snack, studying at his desk.

While studying at his desk and ate a snack.

While studying at his desk with a snack.

He ate a snack while studying at his desk.