Let $f: [a,b] \to \mathbb{R}$ and then let $g : [a,b] \to \mathbb{R}$ given by, $$ g(x)= \begin{cases} f(x) &,\, x \in[a,b]\setminus E \\ K &, \, x \in [a,b]\cap E\end{cases}$$ where $K$ is any real number and $E$ is a countable (finite or countably infinite) subset of $[a,b]$.
Now if $f \in R[a,b]$ then is it the case that $g \in R[a,b]$ with $ \int\limits_{[a,b]}g=\int\limits_{[a,b]} f$?
The notation $f \in R[a,b]$ seems to have caused confusion. Apologies for that, by that notation, I meant $f$ is Riemann integrable on $[a,b]$
My question is motivated by this result. According to it, $f \in R[a,b]$ then is it the case that $g \in R[a,b]$