Try using different data type for input parameter even if you don't use it. See if that helps.
int getValue(int a)
{
int inputValue;
cout << "Enter an integer: ";
cin >> inputValue;
return inputValue;
}
double getValue( double a)
{
double inputValue;
cout << "Enter a floating-point number: ";
cin >> inputValue;
return inputValue;