SANTA CRUZ, Bolivia — As the closing act of a jam-packed 44 hours in Bolivia, Pope Francis on Friday visited a notorious detention center called Palmasola, known as one of the world’s most overcrowded and dangerous prisons, leading the inmates in prayer.

“You may be asking yourselves: “Who is this man standing before us?” Francis told them. “The man standing before you is a man who has experienced forgiveness. A man who was, and is, saved from his many sins.”

He told them that he had little more to offer, but that he wanted to share “what he had,” which is “Jesus Christ, the mercy of the Father.”

“If there are times when you experience sadness, depression, negative feelings, I would ask you to look at Christ crucified,” Francis told them.

“He died for us, for me, so that he could stretch out us his hand and lift us up. Talk to the priests who come here, talk to them! Jesus wants to help you get up, always.”

The Palmasola prison was built for 800 inmates, but currently holds between 3,500 to 5,000 people. Many in Bolivia refer to it as a “town prison” where inmates run the place and money buys survival: a private cell is $300 a month, charged by other criminals.

Leonidas Martin Rodriguez Delgado, one of the inmates, welcomed Francis on behalf of “each of the hearts of those of us deprived of our freedom.” He told the pontiff that Palmasola is “like Sodom and Gomorrah.”

Some years ago, Rodriguez was voted by his fellow prisoners as head of an inmate-run security system, since the police only oversee the perimeter.

Inmate Analia Platino told Francis that he was welcomed as “a voice,” so that from his position of “justice and rectitude,” he could pray for the country’s politicians to have a “change of heart.”

She complained that in Bolivia, it’s “more efficient to hire a corrupt judge than a good lawyer.”

In total, three inmates spoke, thanking the pope and the Catholic Church for being the only institution willing to provide them an education, which, they hope, will give them a future after prison.

The Church has long been present in the prison, offering both primary and secondary level education and Alcoholics Anonymous sessions, as well as university level law-classes, something that can prove to be useful in a country where 90 percent of the nation’s 12,000 prisoners are still awaiting trial.

In 2011, a fierce battle broke out between two enemy factions living inside the prison, resulting in at least 30 people killed, including a two-year old boy who was living there with his mother.

Knowing these realities, the pope encouraged prisoners to “help one another. Do not be afraid to help one another. The devil is looking for rivalry, division, gangs.” The pope had no qualms in addressing Bolivia’s slow justice system, nor the overpopulated facilities that are common throughout the continent.

He told the prisoners that he knew things such as overcrowding, delayed justice, lack of training opportunities, and violence, make reintegration to society hard, so he made an appeal for a speedy and efficient cooperation between institutions to come up with solutions.

“And yet, while working for this, we should not think that everything is lost. There are things that we can do even today.”

The pope asked inmates to “take my greetings to your families,” including grandparents, fathers, mothers, brothers, sisters, couples, children.

“All of them remind us that life is worth living and that we should keep fighting for a better world,” Francis said, eliciting the cheers of the thousands prisoners carrying white and yellow balloons, the papal colors.

Veering off his script, Francis said that prayers of mothers, wives, children and the inmates themselves form a “network” that allows life to go on.

His closing line was the now famous “pray for me,” which he delivers after every speech. However, he didn’t finish there. “Keep praying for me,” he said, “because I, too, have my mistakes, and I, too, must do penance.”

Pope Francis has had a longstanding tradition of visiting prisons or juvenile detention centers that dates back to when he was still Archbishop Jorge Mario Bergoglio of Buenos Aires, where he used to minister to a group of inmates he’s kept in touch with after becoming pope.

When he visits the United States next September, he’ll visit a Philadelphia prison.

After three days in Ecuador and two in Bolivia, the pontiff’s tour through Latin America will continue to Paraguay. He’ll arrive Friday afternoon for another marathon visit that will include two open-air Mass, a visit to a pediatric hospital, and a visit to the population of Bañado Norte, one of the poorest shanty towns in the region.