A Long Island deli owner who held a robber at gunpoint, then let him go after giving him $40 and a loaf of bread, says he got an anonymous letter from the crook that included a $50 bill and a thank-you for saving him from a life of crime.

The mysterious writer apologized to his would-be victim, Mohammad Sohail, saying, “First of all I would like to say I am sorry at the time I had [no] money no food on the table no job and nothing for my family.”

Similar to comments he made on his knees during the incident last May, he said he realized that trying to rob the store with a baseball bat “was wrong but I had [no] choice. I needed to feed my family.”

The letter claimed, “When you had that gun to my head I was 100% that I was going to die,” and said he begged to convert to Islam at that moment only because he feared death.

But the letter-writer said he actually did convert, “decided to become a true Muslim,” and turned his life around after Sohail, 47, spared his life.

“Now I have a new child and good job make good money staying out of trouble and taking care of my family. You gave me forty dollars thank you for sparing my life Because of that you change my life.”

The letter was signed in type: “Your Muslim Brother.”

“That’s the same guy I gave $40 to,” said Sohail, 62, displaying the typewritten letter at his Shirley Express deli yesterday. There was no return address. It was mailed on Long Island the week before Thanksgiving.

“I’m really thrilled,” said Sohail. “I’m very happy for that guy, because he is now doing good for the community.

“He has a job and he is a good person. I really feel great. Thank God he’s doing good. He’s got a new baby and he’s not in jail,” said Sohail.

“When you do good things for somebody, it comes back to you. I gave him $40 and he sent me back $50. It was a good investment,” Sohail laughed.

During the robbery attempt, the failed thief brandished a baseball bat and demanded cash.

But Sohail pulled out a 9mm rifle and disarmed the man — who pleaded for his life on his knees before the deli counter, crying, “I’m sorry! I’m sorry!” and tearfully claiming his family had fallen on hard times.

Suffolk County police declined to comment until they had a chance to look at the letter. Detectives, using video surveillance film of the would-be thief, investigated the robbery but were unable to locate or name the suspect.

kieran.crowley@nypost.com

