1 solutions

  • 0
    @ 2025-11-5 19:09:42

    C++ :

    #include<iostream>
    #include<string>
    #include<cctype>
    using namespace std;
    int main()
    {
    	string s;
    	getline(cin,s);
    	int len=s.size(),ans=0;
    	for (int i=0; i<len; i++)
    		if (isalpha(s[i])) ans++;
    	cout<<ans<<endl;
    	return 0;
    }
    
    • 1

    Information

    ID
    19203
    Time
    1000ms
    Memory
    128MiB
    Difficulty
    (None)
    Tags
    (None)
    # Submissions
    0
    Accepted
    0
    Uploaded By