Determining the level of confidence that must have been used to obtain the margin of error given

I was given this problem for my statistics homework and I don't know how to find the confidence interval based off of the margin of error. Any help would be greatly appreciated.

"Select 3 political polls and note the margin of error, sample size, and percentage favoring the candidate for each. For each poll, determine the level of confidence that must have been used to obtain the margin of error given, knowing the percentage favoring the candidate and the number of participants. Is there a pattern that emerges?"

• As a new contributor, you likely would not know that all homework questions are treated differently than ordinary posts. First, please put in the self-study tag. Second, please accept that we are only supposed give hints about homework, not full answers. Third, the question you asked is kind of basic, it might help if you were to take a stab at it and ask for clarification, and be aware that this question has probably been answered in 1000 other places on the web.
– Carl
Mar 5 '19 at 4:51

Denote the margin of error as $$\epsilon$$. The confidence interval is $$\hat{X} \pm \epsilon$$, where $$\hat{X}$$ denotes the estimated proportion. Write the formula for the confidence interval (which uses sample size, estimate, and confidence level), and use algebra to solve for the for the confidence level.