To simplify the expression \(\frac{2}{1-x} - \frac{1}{x}\), we need to first find a common denominator. The denominator of the first fraction is \((1-x)\) and the denominator of the second fraction is \(x\). The common denominator of these two fractions is \(x(1-x)\).
Now, we need to rewrite each fraction with this common denominator. For the first fraction, we can multiply the numerator and denominator by \(x\), giving us \(\frac{2x}{x(1-x)}\). For the second fraction, we can multiply the numerator and denominator by \((1-x)\), giving us \(\frac{-(1-x)}{x(1-x)}\).
Putting these two fractions together, we get:
\[\frac{2x}{x(1-x)} - \frac{1-x}{x(1-x)} = \frac{2x - (1-x)}{x(1-x)} = \frac{3x-1}{x(1-x)}\]
Therefore, the answer is \(\frac{3x-1}{x(1-x)}\).