SHARE
TWEET

19.11.2019-Pb3

Pop_Flaviu Nov 19th, 2019 107 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # include <iostream>
  2. # include <cstring>
  3. using namespace std;
  4. int main()
  5. {
  6.     int s1,s2,i;
  7.     s1=s2=0;
  8.     char x[100];
  9.     cin.getline (x,100);
  10.     for (i=1;i<=strlen(x);i++)
  11.     {
  12.         if (x[i]>='a'&&x[i]<='z')
  13.         {
  14.             s1++;
  15.         }
  16.          if (x[i]>='A'&&x[i]<='Z')
  17.         {
  18.             s2++;
  19.         }
  20.     }
  21.     cout<<s1<<" "<<s2+1;
  22.     return 0;
  23. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top