Kod:
#include <iostream>
#include <cstring>
using namespace std;
char k1[20], k2[10];
int main(){
strcpy(k1,"Ankara");
strcpy(k2,"Baskent");
cout<<"k1="<<strlen(k1)<<"k2="<<strlen(k2)<<"karakter uzunlugundadir"<<endl;
if(strcmp(k1,k2))
cout<<"farkli"<<endl;
else
cout<<"ayni"<<endl;
cout<<"k1 ve k2 birleþtirildi k1="<<strcat(k1,k2)<<"oldu"<<endl;
cout<<"k1="<<strlen(k1)<<"karakter uzunluga ulasti"<<endl;
return 13;
}