Question: 5 . 1 1 . 4 : Functions with string parameters. 6 1 6 1 4 4 . 3 8 7 7 6 5 4

5.11.4: Functions with string parameters.
616144.3877654.qx3zqy7
Jump to level 1
Complete the function CountChars() that has one string parameter and one character parameter. The function returns the number of characters in the string that are not equal to the character parameter.
Ex: If the input is sdrt \(\mathbf{x}\), then the output is:
4
```
#include
using namespace std;
int CountChars(string inputString, char x){
// Solution goes here
}
int main(){
string inString;
char x;
int result;
cin >> inString;
```
5 . 1 1 . 4 : Functions with string parameters. 6

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!