Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8769407

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T17:20:25+00:00 2026-06-13T17:20:25+00:00

While applying Boyer–Moore string search algorithm to the string : SSIMPLE EXAMPLE with a

  • 0

While applying Boyer–Moore string search algorithm to the string :

SSIMPLE EXAMPLE

with a pattern:

EXAMPLE

the algorithm flows as :

SSIMPLE EXAMPLE ---------------------(1)
EXAMPLE

SSIMPLE EXAMPLE ----------------------------(2)
      EXAMPLE

SSIMPLE EXAMPLE ----------------------------------(3)
        EXAMPLE

but when applying the same algorithm to the same string :

SSIMPLE EXAMPLE

but with a slightly different pattern : (replacing the first E with a T)

TXAMPLE

the algorithm flows as :

SSIMPLE EXAMPLE ------------------- (1)
TXAMPLE

SSIMPLE EXAMPLE ----------------------(2)
       TXAMPLE

SSIMPLE EXAMPLE ---------------------------(3)
        TXAMPLE

From the first example :
In the second step,E is under E

and in the second example :
In the second step,T is not under E but under a space

why is that ? What difference does the alphabets T and E make in the word TXAMPLE and EXAMPLE respectively ?

  • 0 0 Answers
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T17:20:27+00:00Added an answer on June 13, 2026 at 5:20 pm

    In EXAMPLE, the first and last characters are the same, so if you match the last character, then you know that the string has an E at that position. So when you try and shift EXAMPLE along, you have to assume that the E in that position matches the first E in example.

    in TXAMPLE, the last character occurs only at the end of the string, so if you match the last character, then you can shift the string along so far that the next attempted match does not overlap at all with the first one, because E doesn’t match anywhere except at the end of the string.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ok so I've ordered Applying Domain-Driven Design and Patterns: Using .Net , but while
I'm applying UnitTest just for a while, and today I met something very strange.
Trying to figure out how to apply a wildcard concept to something while applying
I have a question regarding applying a custom function to mysql_fetch_assoc while it is
I am writing a GameActivity of a swinging pendulum (in AndEngine). While applying CollisionHandler
I recently tried applying a gradient background to a webpage using only CSS3. while
While applying jQuery UI autocomplete to an input field, I need to filter several
How would you go about applying a background color with CSS only, while only
I'm facing the following error while applying a null coalescing operator. private decimal _currentImpulseId;
I have added an option to apply different theme for my android phone. while

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.