Step 1: Rewrite tan x in terms of sine and cosine. The expression is $\frac{\cos x}{1+\sin x} + \tan x$. Replace $\tan x = \frac{\sin x}{\cos x}$ to put everything in terms of $\sin$ and $\cos$: \[ \frac{\cos x}{1+\sin x} + \frac{\sin x}{\cos x}. \] Step 2: Find a common denominator. The LCD of the two fractions is $\cos x(1+\sin x)$. Combine them: \[ \frac{\cos^2 x + \sin x(1+\sin x)}{\cos x(1+\sin x)}. \] Step 3: Expand the numerator. $\cos^2 x + \sin x + \sin^2 x = (\cos^2 x + \sin^2 x) + \sin x = 1 + \sin x$. We used the Pythagorean identity $\cos^2 x + \sin^2 x = 1$. Step 4: Simplify by cancellation. \[ \frac{1+\sin x}{\cos x(1+\sin x)} = \frac{1}{\cos x}. \] The factor $(1+\sin x)$ cancels from numerator and denominator. Step 5: Recognise the result as secant. $\frac{1}{\cos x} = \sec x$. Step 6: State the final answer. \[ \boxed{\sec x} \]