In Parashat Vayakhel, the Torah says, “Lo Tevaaru Esh Bichol Moshvoteichem Biyom Hashabbat,” “Do not light a fire in all your dwellings on Shabbat” (35:3). The problem with this Pasuk is that it seems to be a waste of words, because the Torah says in the previous Pasuk, “Uvayom Hashevii… Kol Haoseh Bo Melachah Yamut,” “On the seventh day… everyone who does work will die.” If the Torah already commanded us that one who does work on the Shabbat will die, what does it accomplish by telling us that we cannot light a fire? Why is that not included in the original statement about work in general?
Rashi cites from Chazal two possible answers to this question. One opinion says that the Pasuk comes to teach us that lighting a fire is in a separate category from any other work done on Shabbat. For any other work, one receives the death penalty if one does work on Shabbat, but for lighting a fire on Shabbat, one gets Malkut (lashes) instead. Then, he says that the Torah mentioned lighting a fire for an entirely different reason as well, namely, to teach us something about all work done on Shabbat. Since lighting a fire was mentioned separately, it shows us that every other type of work is also in its own separate category; therefore, if one were to do more than one type of work on Shabbat accidentally, he would have to bring more than one sacrifice, one for each type of work done, as opposed to bringing a single sacrifice to atone for all the different types of work.
The Ramban says that the Torah had to specifically tell us about the prohibition of lighting a fire because lighting a fire is used for cooking, and would fall into the category of Ochel Nefesh, work that was done to prepare food. The Pasuk teaches us that even work done for the purpose of obtaining food is prohibited on Shabbat, as opposed to Yom Tov, when this type of work is permitted.