#include <stdio.h>
#include <string.h>
int main() {
char s[64] = "c python c++ java c++ php c++";
char ch = ' ';
char *p = s;
int last_index;
while( (p = strchr(p, ch)) ) {
last_index = p - s;
p++;
}
printf("%d", last_index);
return 0;
}
/*
run:
25
*/