beingtopper.jkp@gmail.com
+91-7529019575
Free Demo

Being Topper

  • Home
  • About Us
    • Founder’s Profile
    • Franchise
    • Women’s Entrepreneurship Development
  • Blog & Events
  • Modules
    • Website Planning and Creation
    • Social Media Marketing Course
    • Search Engine Optimization
    • SEM/PPC Training
  • Branches
    • Rajasthan
      • Ajmer
      • Jaipur
      • Jodhpur
      • Udaipur
      • Kota
      • Sikar
    • Janakpuri
    • Tilak Nagar
    • Noida
    • Chandigarh
    • Mumbai
  • Contact Us

Being Topper

  • Home
  • About Us
    • Founder’s Profile
    • Franchise
    • Women’s Entrepreneurship Development
  • Blog & Events
  • Modules
    • Website Planning and Creation
    • Social Media Marketing Course
    • Search Engine Optimization
    • SEM/PPC Training
  • Branches
    • Rajasthan
      • Ajmer
      • Jaipur
      • Jodhpur
      • Udaipur
      • Kota
      • Sikar
    • Janakpuri
    • Tilak Nagar
    • Noida
    • Chandigarh
    • Mumbai
  • Contact Us
  • Home
  • About Us
    • Founder’s Profile
    • Franchise
    • Women’s Entrepreneurship Development
  • Blog & Events
  • Modules
    • Website Planning and Creation
    • Social Media Marketing Course
    • Search Engine Optimization
    • SEM/PPC Training
  • Branches
    • Rajasthan
      • Ajmer
      • Jaipur
      • Jodhpur
      • Udaipur
      • Kota
      • Sikar
    • Janakpuri
    • Tilak Nagar
    • Noida
    • Chandigarh
    • Mumbai
  • Contact Us

Being Topper

  • Home
  • About Us
    • Founder’s Profile
    • Franchise
    • Women’s Entrepreneurship Development
  • Blog & Events
  • Modules
    • Website Planning and Creation
    • Social Media Marketing Course
    • Search Engine Optimization
    • SEM/PPC Training
  • Branches
    • Rajasthan
      • Ajmer
      • Jaipur
      • Jodhpur
      • Udaipur
      • Kota
      • Sikar
    • Janakpuri
    • Tilak Nagar
    • Noida
    • Chandigarh
    • Mumbai
  • Contact Us
Algorithm Design and analysis ProgramsB.tech notesBCA NOTESC++ programInformation technology

c++ program to perform naive string matching

Being Topper 25/05/2013 0 Comments

WRITE A PROGRAM TO PERFORM NAÏVE STRING MATCHING

#include<iostream.h>
#include<conio.h>
#include<string.h>

void main()
{
clrscr();
intn,m,s;
char t[50], p[50];
cout<<"Enter text"<<endl;
cin>>t;
cout<<"Enter pattern"<<endl;
cin>>p;
m=strlen(p);
n=strlen(t);
for(s=0;s<=(n-m);s++)
{
for(int i=0;i<=m;i++)
{
if(t[s+i]!=p[i])
break;
}
if(i=m)
cout<<"Valid Shift"<<endl;
cout<<"shift is"<<s;
}
getch();
}

OUTPUT :

 

C++ programs for the implementation of Breadth First Search ...

Output-for-activity-breadth -first-search

Algorithm and design analysis b.tech information technology notes c++ program to perform naive string matching c++ programs naive string matching WRITE A PROGRAM TO PERFORM NAÏVE STRING MATCHING
1524 Views
AboutBeing Topper
In Socials:
Prevc++ program to perform breadth first search25/05/2013
VBScript Full Program for structure | Structure in VBScript18/01/2014Next

Related Posts

AppletB.tech notesBCA NOTESInformation technologyJava ProgramsPrograms/Algorithm

Java Program for working Pacman game

Java Program/source code for working Pacman Game. This program is primarily based on...

Being Topper 18/02/2014
BCA NOTES

Program in VB.Net to build a class which implements an interface

Que : Write a program in VB.Net to build a class which implements an interface Ans:...

Being Topper 17/10/2014
Categories
Recent Posts
  • Vipin Khuttel Inspires Entrepreneurs at Networking Meet in Gurgaon
  • Vipin Khuttel Founder of Being Topper Recognized for Advancing Digital Literacy and Social Empowerment
  • Vipin Khuttel Organizes International Conference for Digital Excellence 2, Elevating the Future of Technology
  • India’s Top Occult Science Enthusiasts Gather at AgyatOnSearch – Awards & Seminar in New Delhi
  • India’s Leading Digital Marketer, Vipin Khuttel Interacted with Top Influencers of Delhi at BJP West Delhi’s Event

Copyright © 2025 Being Topper ® . All Rights Reserved