This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Difference b/w "REGEXP" or "STRING MATCH"

Old posts that have not been replied to for several years.
Locked
User avatar
awyeah
Revered One
Posts: 1580
Joined: Mon Apr 26, 2004 2:37 am
Location: Switzerland
Contact:

Difference b/w "REGEXP" or "STRING MATCH"

Post by awyeah »

Hello,

Well I have some scripts like a caps kicker, drone nick
kicker, control codes kicker, and etc etc. protection
scripts for my bot.

Both 'regexp' and 'string match' functions can be used
in these scripts to match certain characters in nicks,
and texts.

I was wondering which is a faster way, I mean which
command excutes a faster output "regexp" or "string match"

This faster output que, could be efficient to kick-ban people
with a faster ammount of time with minimal lag.

'regexp' i know is a complex matching sequence, while
string match is just the basic one.

Which will have a faster output? and which would have
an efficient, accurate (better) output?
·­awyeah·

==================================
Facebook: jawad@idsia.ch (Jay Dee)
PS: Guys, I don't accept script helps or requests personally anymore.
==================================
User avatar
strikelight
Owner
Posts: 708
Joined: Mon Oct 07, 2002 10:39 am
Contact:

Post by strikelight »

Sounds like you already know the answers to your questions...

string match is ofcourse faster, but regexp provides complex pattern matching..

as for efficiency, it just matters what you want to do... if it can be done with string match, then that is the efficient method... otherwise the efficient method defaults to regexp (or even scan in some cases)..

Short answer... use string match when possible..
Locked