Advertisement
artemkaa

Untitled

Jul 28th, 2015
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.55 KB | None | 0 0
  1. #include <iostream>
  2. #include <string>
  3.  
  4. using namespace std;
  5. int type_definition (string s)
  6. {
  7.     bool flag = false;
  8.     if ((s[0] == 'R') and (s.find('C') > 0))
  9.     {
  10.         flag = true;
  11.     }
  12.     if ((int(s[1]-'0') >= 0) and (int(s[1]-'0') <=9) and (flag == true))
  13.     {
  14.         return 1;
  15.     }
  16.     else
  17.     {
  18.         return -1;
  19.     }
  20. }
  21. void (string aa_number)
  22. {
  23.     string RXCY = R;
  24.     string numberPart;
  25.     for (int i = 0; i < )
  26. }
  27.  
  28. int main()
  29. {
  30.     string str;
  31.     cin >> str;
  32.     cout << type_definition(str);
  33.     return 0;
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement