An element not belong to any proper prime ideal in given commutative ring with 1. It may be a dumb question but. Assume $R$ be a commutative ring with unity 1. Let $x\in R$ given.
If $x$ is invertible I know that it cannot be in any proper ideal. If $x$ is not invertible can I say that there should be at least one prime ideal contains that. Of course I am talking about nontrivial cases, such as R being a field etc.
I tried to construct an ideal contains it but even the set $\{x\in R| \text{x is non invertible}\}$ is not an ideal iff $R$ is not local ring.
 A: With our OP Jale'de jaled we take $R$ to be a unital commutative ring with unit $1$.
Then if
$x \in R \tag 1$
is invertible, and
$J \subset R \tag 2$
is an ideal of $R$ with
$x \in J, \tag 3$
we have
$1 = x^{-1}x \in J \tag 4$
so for any
$y \in R \tag 5$
it follows that
$y = y \cdot 1 \in J \tag 6$
which implies
$R \subset J; \tag 7$
combining (2) and (7) yields
$J = R, \tag 8$
and we have shown that no invertible element is contained in a proper ideal, that is one which is not the whole of $R$.
If $x$ is not invertible, we may consider the principal ideal
$xR = \{xy, \; y \in R \}; \tag 9$
note that
$1 \notin xR, \tag{10}$
lest
$\exists z \in R, \; xz = 1, \tag{11}$
i.e.,
$z = x^{-1}, \tag{12}$
in contradiction to the assumption that $x$ has no inverse.  In light of (10), $xR$ is a proper ideal, hence there exists a maximal ideal
$M \subsetneq R \tag{13}$
with
$x= x \cdot 1 \in xR \subset M \subsetneq R, \tag{14}$
and since every maximal ideal is prime, we see that $x$ is contained in some prime ideal.
