For a particular thermodynamic process defined as $P=f(V)$ or $T=g(V)$, where $f$ and $g$ are functions with constants with appropriate units. How to find the molar specific heat of the gas? Given that adiabatic exponent is $\gamma$. Is there a general method to solving these kinds of problems?
$f(V)$ and $g(V)$ cannot be specified independently. Once you specify $V$, then you know $P=f(V)$, and once you know $P$ and $V$ (assuming you know the quantity of material), from the equation of state, you know $T$.
use the first law in ideal, differential form U=nC.dT where C is molar heat capacity at constant volume which is known for a gas, W=P.dV , Q=nC.dT where C is the thing we need and solve differential equation.