Advertisement
ioanaasdfgh

v53 siruri de caractere

Nov 15th, 2018
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.22 KB | None | 0 0
  1. #include<iostream>
  2. #include<string.h>
  3. using namespace std;
  4. int main ()
  5. {
  6.     char s[20];
  7.     int i;
  8.     cin.get(s,20);
  9.     cin.get();
  10.     strcpy(s,"bacalaureat");
  11.     i=strchr(s,'a')-s;
  12.  
  13.     cout <<s<<" "<< i;
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement