Function that is absolutely continuous but not $C^1$ 
*

*I would like to know example of a function that is absolutely
continuous on a compact subset of real line but is not $C^1$.

*Does always $C^1$ imply absolute continuity on unbounded subsets of real line? I know that it is so on compact subsets.



Let $-\infty<a<b<\infty$ . A function $u:[a,b]\to\mathbb{R}$ will be absolutely continuous if and only if, $u'$ does exist almost everywherem $u'\in L^1(a,b)$ and $$u(x)=u(a)+\int_a^x u'(t)dt.$$

Therefore, take any function $v\in L^1(a,b)$ and let $$u(x)=\int_a^x v(t)dt.\tag{1}$$
You can verify that $u'=v$ a.e. and therefore, $u$ is absolutely continuous. Now you have plenty of examples for your first dot. For example, let $a<c<d<b$ and let $v=\chi_{[c,d]}$. Note that $v\in L^1(a,b)$ and therefore, if $u$ is defined as in $(1)$ then, $u$ is absolutely continuous.
For your second dot, you can say for sure that the function is absolutely continuous on compact sets, however, as pointed out in the comments, if the derivative is integrable then, you can conclude more. To understand this, try to get a better understanding of the above equivalence.
