Find Jobs
Hire Freelancers

Search algorithm using prime numbers

$10-30 USD

Completed
Posted about 4 years ago

$10-30 USD

Paid on delivery
I am thinking of using prime numbers as a way to search (and scan) through a text. In regular string matching, the algorithm will compare each character of string to be compared sequentially. My idea was to skip the i-th character by a value of a prime number. For example, if nth character doesn’t match, see if it matches after skipping 7 characters (a prime number) more in the string. I am thinking of storing few prime numbers in an array then using it as a variable to skip the characters during the scan. For example, if skipping 7 characters is too much, reduce to 3 characters or the opposite, increase to skipping 17 characters. I would like this algorithm made in C for performance. I have included a pseudo code and C mix as a sketch for you to see what the algorithm is like.
Project ID: 24149286

About the project

1 proposal
Remote project
Active 4 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
hi , it's an easy task for me and i can do it as required and on time . thanks in advance .
$30 USD in 7 days
5.0 (27 reviews)
4.5
4.5

About the client

Flag of JAPAN
Hiratsuka-shi, Japan
5.0
29
Payment method verified
Member since Aug 3, 2007

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.