How to solve polynomial modular equation to create a correct decryption algorithm
We can write $m$ as 

$$m = (c -3 + 4k) \cdot 5^{-1} \pmod n$$

There is a problem here that the 5 may not has an inverse for every $n$. For example, it doesn't have an inverse in $\mathbb{Z}_{10}$.

It has an inverse in $\mathbb{Z}_{n}$ if $\gcd(5,n) =1$.

If it has the inverse one can find it by the Extended Euclidean Algorithm to form the Bézout's identity $5 x + n y = 1$ then take $\bmod n $ to achive the inverse as $5 x = 1 \bmod n$



As pointed by poncho, for finding the inverse of $5$ there is a better method $$(n+1)/5, (2n+1)/5, (3n+1)/5, (4n+1)/5$$ if the inverse exist. To see the inverse exist, one first needs to see that the $\gcd(5,n)=1$. 

In the general case, after some threshold, this approach may not be helpful, since testing all $$(n+1)/x, (2n+1)/x, \ldots, ((x-1)n+1)/x$$ will pass the calculation of the Bézout's identity.