f(x) = {

2 if x ! [0, 1)
−1 if x = 1
3 if x ! (1, 2]
−5 if x ! (2, 3)
20 if x = 3 }
Prove that the function is Riemann integrable over [0, 4] and calculate
its Riemann integral over [0, 4].

This is a trivial application of the definition of the Riemann integral, see here:

http://en.wikipedia.org/wiki/Riemann_integral

There is also a general theorem:

"It can be shown that a real-valued function f on [a,b] is Riemann-integrable if and only if it is bounded and continuous almost everywhere in the sense of Lebesgue measure."