Suppose you have $$ \mathbb{D}=\{ \frac{p}{10^n}\mid p \in \mathbb{Z}, n \in \mathbb{N} \}.$$ Show that every ideal of this ring is principal.
So my approach was to first find a potential candidate for an ideal $I$ of $\mathbb{D}$ such that $a\mathbb{D} = I$. I reasoned first that $I \cap \mathbb{Z}$ is a subgroup of $\mathbb{Z}$ so of a form $a \mathbb{Z}$, thus then I showed that $a\mathbb{D} \subset I$. Now I need to show that $I \subset a \mathbb{Z}$, and here I have issues. If $x \in I$ then I should somehow find $(p,n) \in \mathbb{Z} \times \mathbb{N}$ so that $x = a \frac{p}{10^n}$ but I am unable to find a way!
You already have that $a\mathbb{Z} = I\cap\mathbb{Z}$ — so you're nearly there!
Let $x=\frac{p}{10^n}\in I$. Then $p=10^n x\in a\mathbb{Z}$ as $10^n\in\mathbb{D}$. So $a|p$, and there must exist $d=\frac{(p/a)}{10^n}\in\mathbb{D}$ such that $x=ad$.