Find two partitions P,Q of $[a,b]$ such that $||Q||<||P||$ but $\underline{S}(f,P)=\underline{S}(f,Q)$ I'm trying to answer the following exercise:

Give an example of a bounded function $f:[a,b]\rightarrow\mathbb{R}$, with two partitions P,Q of $[a,b]$ such that $||Q||<||P||$ but $\underline{S}(f,P)=\underline{S}(f,Q)$

Where $||Q||$ is the norm of Q and $||P||$ is the norm of P; $\underline{S}(f,P)$ and $\underline{S}(f,Q)$ are the inferior sums.
I've tried to solve it with the following attempts, but with none of them I got that $\underline{S}(f,P)=\underline{S}(f,Q)$:
$f: [0,2]\rightarrow \mathbb{R}$ such that $f(x)=e^x \: \forall x\in [0,2] $; with the partitions $P=\{0, \frac{1}{2}, 1, \frac{3}{2}, 2\}$ and $Q=\{0, \frac{1}{4}, \frac{1}{2},\frac{3}{4}, 1, \frac{5}{4},\frac{3}{2}, \frac{7}{4}, 2\}$, where it's clear that $||Q||=\frac{1}{4}<\frac{1}{2}=||P||$, but $\underline{S}(f,P)<\underline{S}(f,Q)$
And I got to the same result with this attempt:
$f: [0,2]\rightarrow \mathbb{R}$ such that $f(x)=x^2 \: \forall x\in [0,2] $; with the partitions $P=\{0, \frac{1}{2}, 1, \frac{3}{2}, 2\}$ and $Q=\{0, \frac{1}{4}, \frac{1}{2},\frac{3}{4}, 1, \frac{5}{4},\frac{3}{2}, \frac{7}{4}, 2\}$, where it's clear that $||Q||=\frac{1}{4}<\frac{1}{2}=||P||$, but $\underline{S}(f,P)\neq\underline{S}(f,Q)$
I know these are really simple functions but I was trying to see if with those I could get to some function that worked (which it's clear it didn't), and I'm guessing that only certain functions are capable of doing so.
If you could help me with an example I'd appreciate it.
Thank you in advance.

Generally $\underline{S}(f, P)\le \underline{S}(f,Q)$ if $Q$ is a refinement of $P$. But for some special partitions $P$ and $Q$ and some function $f$, $\underline{S}(f, P)$ and $\underline{S}(f,Q)$ may be the same. For example, let
$$ f(x)=\left\{\begin{array}{ll} \frac12 \text{ if }x\in[0,\frac12]\\
\frac32 \text{ if }x\in(\frac12,1]\\
1 \text{ if }x\in(1,\frac32]\\
2 \text{ if }x\in(\frac12,2]
\end{array}\right. $$
be a piecewise constant function. Then for the partitions $P=\{0, \frac{1}{2}, 1, \frac{3}{2}, 2\}$ and $Q=\{0, \frac{1}{4}, \frac{1}{2},\frac{3}{4}, 1, \frac{5}{4},\frac{3}{2}, \frac{7}{4}, 2\}$, we have
$$ \underline{S}(f,P)=\frac12\cdot\frac12+\frac32\cdot\frac12+1\cdot\frac12+2\cdot\frac12=\frac52 $$
and
$$ \underline{S}(f,Q)=\frac12\cdot\frac14+\frac12\cdot\frac14+\frac32\cdot\frac14+\frac32\cdot\frac14+1\cdot\frac14+1\cdot\frac14+2\cdot\frac14+2\cdot\frac14=\frac52. $$
