To add to @Crostul's comment, if at some step you get $$f^{(n)}(x) = |x|$$ then you have reached a dead end and this is indeed not differentiable further (because the derivative at $x=0$ does not exist, although the function is continuous there).
Any polynomial or simple exponent is infinitely differentiable (exponents cover sines and cosines as well)...
UPDATE
For an example of a function that would reach such a dead end, consider
$$
f(x) = \begin{cases} x^3, & x \ge 0 \\ -x^3, & x < 0 \end{cases}
$$
and note that
$$
f'(x) = \begin{cases} 3x^2, & x \ge 0 \\ -3x^2, & x < 0 \end{cases}
$$
and
$$
f''(x) = \begin{cases} 6x, & x \ge 0 \\ -6x, & x < 0 \end{cases}
= 6|x|
$$
and you have reached a dead end.
this is a little late, and so I’m sure you have come across an answer by now! But I shall write the below nonetheless, as it may help others. Firstly we need to realize what the Cauchy-Riemann equations tell us. If you derive them (you can look this derivation up it comes from the definition of the derivative actually), you will see that they come from the assumption that a complex function is differentiable at the point of interest. So, if we are differentiable, then we satisfy Cauchy-Riemann. Which also tells us that the contrapositive is true, so that the statement “if we do not satisfy Cauchy-Riemann, then we are not differentiable” is true. Now onto analyticity, for a function to be analytic at the point P in the complex plane, it must be differentiable in a neighborhood of P. So Cauchy-Riemann must be satisfied in that neighborhood of P. It is a stricter condition, as we can be differentiable at a point but not necessarily analytic/holomorphic if we are not differentiable in the neighborhood.
So now let’s analyze your question. You have asked “can a function be analytic if it doesn’t satisfy CR?” Let’s do a proof of falsity by contradiction: assume a function can be analytic and not satisfy CR at the point P (I’m making your question slightly more specific). This would mean that we are differentiable in a neighborhood of a point P but do not satisfy CR at the point P. If we do not satisfy CR at the point P, then we are not differentiable at P (as per the contrapositive statement above). But that would mean that we are not differentiable in a neighborhood of P since the neighborhood of P includes itself! So we arrive at our contradiction, that we started as differentiable and became non-differentiable in a neighborhood of P which contradict one another, so we abandon the assumption that we are analytic. Thus, if we do not satisfy CR at a point P, then we cannot be analytic at the point P.
Now suppose that your question became “can we be analytic if we do not satisfy Cauchy-Riemann at some point or set of points in the neighborhood of P?” Observe that this is as general as we can make your question! The proof to this is just the same as above, assume you can be analytic at P and do not satisfy CR at some point or set of points in a neighborhood of P, then we are not differentiable at some point or set of points in a neighborhood of P, so we are not differentiable in the neighborhood of P, and so we are lead to the same contradiction as above. To be specific, it is the contradiction that we started as differentiable but had information (CR not satisfied) to show that we are not differentiable and so we are lead to the contradiction and therefore must abandon the assumption.
So we can never be analytic at a point P without satisfying the Cauchy-Riemann equations in a neighborhood of P. This is the ultimate punch line of the demonstration above. I hope things have been made more clear from this, it is good practice in mathematics to try and prove claims that you make or potential answers to questions you have, it allows you to practice what you’ve learned as well and maybe even reinforce your knowledge or learn something new!
Have a great day.
Best Answer
Take an integrable discontinuous function (such as the sign function), and integrate it three times. Its first integral is the absolute value function, which is continuous: as are all of its other integrals.