I realize that I can sin by some action (for example, murder or theft), but I have never understood how someone can sin by inaction, by not doing something. How is that possible?
Yes, sins of commission (such as the examples you cited) are pretty easy to recognize. A sin of omission can easily slip under a person’s radar because “That’s just the way life is” or “Nobody else took action in that situation.”
On November 22 this year, the Gospel for Christ the King Sunday will be Matthew 25:31–46 (Jesus separating the sheep from the goats at the Last Judgment). Those condemned (the goats) are not identified by deliberate actions against people who are hungry, thirsty, strangers, naked, sick, or in prison. Instead, those who are condemned have only one thing in common: one or more sins of omission, a failure to recognize women, men, and children in great need as people also loved by God and intended to share eternal life with God.
If that story were longer, we might hear the condemned people asking: “Who knew they mattered?,” “Everybody suffers at some time,” or “Life is always rough.”
The prophet Amos denounces the Israelites who reclined on ivory couches, ate well, “but are not made ill by the collapse of Joseph” (6:6b). The prophet Isaiah speaks for God in saying, “Trample my courts no more! To bring offerings is useless. . . . Make justice your aim: redress the wronged, hear the orphan’s plea, defend the widow” (1:13a, 17b).
In the synagogue of Nazareth, Jesus read from Isaiah 61:1 about bringing glad tidings to the poor, proclaiming liberty to captives, and bringing recovery of sight to the blind and release to prisoners.
The rich man in Luke 16:19–31 was not deliberately cruel to Lazarus, but he ignored a very needy man at his gate. James 2:14–16 tells us that responding to a hungry person needing clothes by saying, “Goodbye and good luck! Keep warm and well fed,” while making no attempt to address those needs indicates a lifeless faith.
The overall sin in all these examples—and Scripture offers many more—is deliberately making invisible someone in great need. No one can do everything, but everyone can do something.