#include<bits/stdc++.h>
using namespace std;

int main(){
	string s;
	int cnt = 0;

	while(cin >> s){
		if(s.length() == 1){
			cnt++;
			continue;
		}

		int center = s.length()/2;

		if(s.length() % 2 == 1){
			cnt++;

			for(int i = 0, j = s.length()-1; i < center, j > center; i++, j--){
				if(s[i] != s[j]){
					cnt--;
					break;
				}
			}
		}
		else if(s.length() % 2 == 0){
			cnt++;
			for(int i = 0, j = s.length()-1; i < center, j >= center; i++, j--){
				if(s[i] != s[j]){
					cnt--;
					break;
				}
			}
		}
	}
	cout << cnt << endl;
}