NEW YORK — Two measly dollars stood between a New York City man and freedom, but he had no idea. Instead, a 41-year-old Queens man remained in a Rikers Island c...

NEW YORK — Two measly dollars stood between a New York City man and freedom, but he had no idea.

Instead, a 41-year-old Queens man remained in a Rikers Island cell from November 2014 to April 2015, his new lawyers argued before a judge last week, according to the New York Daily News.

Aitabdel Salem was initially jailed on $25,000 bail after allegedly attacking a police officer who arrested him for shoplifting from a Manhattan Zara store. The judge also ordered $1 bail for two other, minor charges — tampering and mischief.

When prosecutors initially failed to get an indictment on the assault charge just days after his arrest, Salem should have been able to walk free for less than the cost of a subway ride.

Salem, a native of Algeria, claims his first lawyer, Stephen Pokart, never explained the change in bail status to him.

Unaware that he could have posted the $1 bail on the other two charges, it would be almost five months before Salem left Rikers Island in May of 2015. However, Salem missed his arraignment on the assault charge because of a court date mix-up, according to his lawyers, and he was tossed back behind bars — this time on $30,000 bail.

“(Salem) was shocked and dismayed and frustrated that his case was unconscionably mishandled and there was no communication by his attorney telling him his bail was $2 which he could have made at any moment,” argued one of Salem’s new attorneys, Glenn Hardy at a recent court hearing. “You can’t do what you don’t know and if you’re a defendant in a criminal case you certainly have a right to rely upon the system (to know) what your next court date is.”