find character in string c++

#include <iostream>
#include <string>
using namespace std;

int main() {
    string str = "Hello, World!";
    char ch = 'o';
    size_t found = str.find(ch);

    if (found != string::npos) {
        cout << "Found at position: " << found << endl;
    } else {
        cout << "Not found" << endl;
    }

    return 0;
}