Suppose a,b are real numbers, if a is rational and ab is irrational, then b is irrational (Is my solution correct?) 
Suppose $a,b$ are real numbers, if $a$ is rational and $ab$ is irrational, then $b$ is irrational.

Solution: Proof by contraposition
$$b = \frac{p}{q}$$
$$ a = \frac{j}{k}$$
where $p,q,j,k$ are integers and $k,j \neq 0$.
$$ ab = \frac{pj}{qk} $$
 A: The proof is correct. Note that the proof uses only the property that the rationals are closed under multiplication $\,\color{#c00}{\rm(CM)}\,$ so it will work more generally for any such subset $\,R\,$ of "numbers", i.e.  $$\smash[t]{\, a\in R,\ ab \not\in  R\,\Rightarrow\, b\not\in  R,\ \  {\rm else} \ \ a,b\in R\,\stackrel{\rm\color{#c00}{(CM)}}\Rightarrow\, ab\in R,\ \ \ {\rm contra\ hypothesis.}}$$
Hence $\,a\,$ integral , $\,ab\,$ nonintegral $\,\Rightarrow\, b\,$ nonintegral
and $\,a\,$ algebraic , $\,ab\,$ transcendental $\,\Rightarrow\, b\,$ transcendental
and $\,a\,$ constant, $\,ab\,$ nonconstant $\,\Rightarrow\, b\,$ nonconstant, $ $ for functions, polynomials, etc.
The statement is just a contrapositive form of the fact that $\,R\,$ is closed under multiplication, i.e. writing out the logical equivalance explicitly, using $\ x\Rightarrow y\, \equiv\, \lnot x\ \ {\rm or}\ \ y,\,$ we have
$$\begin{eqnarray}  && a\in R\ {\rm and}\ ab\not\in R\,\Rightarrow\ b\not\in R \\
\equiv\, && a\not\in R\ \ \,or\ \ ab\in R\ \  {\rm or}\ \  b\not\in R \\
\equiv\, && a\not\in R\ \ \,or\ \ b\not\in R\ \ \,{\rm or}\ \ ab\in R \\
\equiv\, && a\in R\ {\rm and}\ b\in R\,\Rightarrow\ ab\in R \\
\end{eqnarray}$$
