I am a new blockchain developer as well as Solidity. I am having a function call problem in the code below. The compiler is throwing some warning. Though the code runs fine, I want to understand the error. Thanks.
function add() public view returns(uint256){
uint256 a= 5;
uint256 b= 4;
uint256 sum = a + b;
return sum;
}
Warning: Function state mutability can be restricted to pure