#include <stdio.h> #include <locale.h> int main() { setlocale(LC_ALL,"Turkish"); // Girdi char string[]="g�zel olsun do�ru olsun rahat olsun"; char subsequence[]="godoro"; //��kt� int found; // Bul int i=0; int j=0; // Alt ard���mdaki her karakter while (subsequence[i] != '\0') { // Ayr� oldu�u s�rece ilerle while ((subsequence[i] != string[j]) && string[j] != '\0') { j++; } // Sicimin sonuna gelindiyse ��k if (string[j] == '\0') break; j++; i++; } // Alt ard���m sonuna gelinebildi mi if (subsequence[i] == '\0'){ found=1; } else { found=0; } // Bas printf("Sicim: %s \r\n",string); printf("Alt ard���m: %s \r\n",subsequence); if (found){ printf("Bulundu \n"); } else { printf("Bulunamad� \n"); } return 0; }Dosyayı İndir