a) f(x)=xsinx1.
b) Yes. The Cantor set is given by
C={x∈[0,1):x=j=1∑∞bj3−j, bj∈{0,2}}.
There is an one-to-one mapping f:[0,1)→C. Indeed, for
x=j=1∑∞aj2−j, aj∈{0,1} we set
f(x)=j=1∑∞(2aj)3−j. Hence C is
uncountable.
For k=1,2,… and i=0,1,2,…,2k−1−1 we set
ak,i=3−k(6j=0∑k−2aj3j+1),bk,i=3−k(6j=0∑k−2aj3j+2),
where i=j=0∑k−2aj2j, aj∈{0,1}. Then
[0,1)∖C=k=1⋃∞i=0⋃2k−1−1(ak,i,bk,i),
i.e. the Cantor set consists of all points which have a trinary
representation with 0 and 2 as digits and the points of its compliment
have some 1's in their trinary representation. Thus,
i=0⋃2k−1−1(ak,i,bk,i) are all points
(exept ak,i)
which have 1 on k-th place and 0 or 2 on the j-th (j<k) places.
Noticing that the points with at least one digit equals to 1 are
everywhere dence
in [0,1] we set
f(x)=k=1∑∞(−1)kgk(x).
where gk is a piece-wise linear continuous functions with values at
the knots
gk(2ak,i+bk,i)=2−k,gk(0)=gk(1)=gk(ak,i)=gk(bk,i)=0,
i=0,1,…,2k−1−1.
Then f is continuous and f “crosses the axis” at every point of
the Cantor set.