Advertisement
Nickpips

Untitled

Dec 6th, 2015
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. #include <iostream>
  2. #include <vector>
  3. #include <string>
  4. #include <math.h>
  5.  
  6. using namespace std;
  7.  
  8. int main()
  9. {
  10. int e = 0;
  11. cin >> e;
  12. char log[1001];
  13. cin.getline( log, 1001 );
  14. for( int i = 0; i < e; i++ )
  15. {
  16. cin.getline( log, 1001 );
  17. int ans = 1;
  18. for( int j = 0; log[j] != '\0'; j++ )
  19. if( log[j] == '\\' || log[j] == '/' || log[j] == '-' || log[j] == '|' )
  20. ans++;
  21. cout << "Cyborg #" << (i+1) << ": " << ans << " piece" << (ans==1 ? "? You're supposed to be stronger than this!" : "s!") << endl;
  22. }
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement