I had a situation where I struggled to make my program run. So after a great struggle I got it working. Is this the correct statement I can use here? Or is there any other sentence like I made it work ? I got confused. Is there any other sentence that suits this situation?
Close, but no cigar!
The correct phrase to use is I got it working or I got it to work.
Also, at the beginning of your question, “I got a situation” should be I had a situation.