Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C Programming > what is regular expression

Reply
Thread Tools

what is regular expression

 
 
MJ
Guest
Posts: n/a
 
      07-12-2005
HI
I want to know what is mean by regular expression in C
Mayur

 
Reply With Quote
 
 
 
 
SM Ryan
Guest
Posts: n/a
 
      07-12-2005
"MJ" <(E-Mail Removed)> wrote:
# HI
# I want to know what is mean by regular expression in C

A regular expression is pattern with certain restrictions (it
cannot match nested parentheses) that identifies a set of strings.
There are various regular expression packages available, each
with small variations in how the regular expression is expressed.

A regular expression is equivalent to a finite state machine;
if you want to recognise a predetermined RE in a C program, you
can convert the expression to an FSM and encode it with gotos.

--
SM Ryan http://www.rawbw.com/~wyrmwif/
We found a loophole; they can't keep us out anymore.
 
Reply With Quote
 
 
 
 
Keith Thompson
Guest
Posts: n/a
 
      07-12-2005
"MJ" <(E-Mail Removed)> writes:
> I want to know what is mean by regular expression in C


Nothing. The C language has no support for regular expressions,
though there are libraries (some that happen to be written in C) that
support regular expressions.

A Google search for "regular expressions" is likely to be more
fruitful than posting to a newsgroup where the question is off-topic.

--
Keith Thompson (The_Other_Keith) http://www.velocityreviews.com/forums/(E-Mail Removed) <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
 
Reply With Quote
 
Kenny McCormack
Guest
Posts: n/a
 
      07-12-2005
In article <(E-Mail Removed) .com>,
MJ <(E-Mail Removed)> wrote:
>HI
>I want to know what is mean by regular expression in C


C has expressions (e.g., 2+2) and they are used regularly.
In fact, it is pretty hard to write a C program without using at least one
such expression.

HTH

 
Reply With Quote
 
CBFalconer
Guest
Posts: n/a
 
      07-12-2005
MJ wrote:
>
> I want to know what is mean by regular expression in C


It has to do with the lack of facial grimaces following a long bout
of constipation. From which you may conclude that this has nothing
to do with the C language, and that you are off-topic here. Such
books as "Software Tools", or "The Practice of Programming", etc.
may produce some clues.

--
"If you want to post a followup via groups.google.com, don't use
the broken "Reply" link at the bottom of the article. Click on
"show options" at the top of the article, then click on the
"Reply" at the bottom of the article headers." - Keith Thompson


 
Reply With Quote
 
SM Ryan
Guest
Posts: n/a
 
      07-12-2005
(E-Mail Removed) (Kenny McCormack) wrote:
# In article <(E-Mail Removed) .com>,
# MJ <(E-Mail Removed)> wrote:
# >HI
# >I want to know what is mean by regular expression in C
#
# C has expressions (e.g., 2+2) and they are used regularly.
# In fact, it is pretty hard to write a C program without using at least one
# such expression.

Unable to settle for mere obnoxiousness, you now have to deliberately
spread misinformation.

--
SM Ryan http://www.rawbw.com/~wyrmwif/
One of the drawbacks of being a martyr is that you have to die.
 
Reply With Quote
 
Sensei
Guest
Posts: n/a
 
      07-12-2005
On 2005-07-12 01:40:36 -0500, "MJ" <(E-Mail Removed)> said:

> HI I want to know what is mean by regular expression in C Mayur


C has *no* knowledge of regexp. A regular expression is a string that
describes a language that can be recognized by a finite-state machine,
For better knowledge, google for it, or probably better, wikipedia.

If you want a library that helps you in dealing with regexp, it's
another topic...

--
Sensei <(E-Mail Removed)>

cd /pub
more beer

 
Reply With Quote
 
Kenny McCormack
Guest
Posts: n/a
 
      07-12-2005
In article <(E-Mail Removed)>,
SM Ryan <(E-Mail Removed)> wrote:
>(E-Mail Removed) (Kenny McCormack) wrote:
># In article <(E-Mail Removed) .com>,
># MJ <(E-Mail Removed)> wrote:
># >HI
># >I want to know what is mean by regular expression in C
>#
># C has expressions (e.g., 2+2) and they are used regularly.
># In fact, it is pretty hard to write a C program without using at least one
># such expression.
>
>Unable to settle for mere obnoxiousness, you now have to deliberately
>spread misinformation.


What misinformation? What did I say that was either untrue or OT?

Please be specific. Give examples.

 
Reply With Quote
 
Clint Olsen
Guest
Posts: n/a
 
      07-12-2005
On 2005-07-12, MJ <(E-Mail Removed)> wrote:
> I want to know what is mean by regular expression in C
> Mayur


Regular expressions are actually more of a language topic. You'd probably
have better luck learning about those in comp.compilers and
comp.programming. Having said that, there are library routines for
creating and manipulating regular expressions in C, but they are not part
of the standard and thus not really topical to a group focused on ANSI C.

See regcomp(1) for more info on the C routines on your favorite UNIX
variant.

-Clint
 
Reply With Quote
 
CBFalconer
Guest
Posts: n/a
 
      07-12-2005
Kenny McCormack wrote:
> SM Ryan <(E-Mail Removed)> wrote:
>> (E-Mail Removed) (Kenny McCormack) wrote:
>># MJ <(E-Mail Removed)> wrote:
>>#>
>>#> I want to know what is mean by regular expression in C
>>#
>># C has expressions (e.g., 2+2) and they are used regularly.
>># In fact, it is pretty hard to write a C program without using at
>># least one such expression.
>>
>> Unable to settle for mere obnoxiousness, you now have to
>> deliberately spread misinformation.

>
> What misinformation? What did I say that was either untrue or OT?
>
> Please be specific. Give examples.


Note the source. While continuing to attempt to foul up as many
newsreaders as possible with his obnoxious quote mark, he complains
about a perfectly rational answer.

--
"If you want to post a followup via groups.google.com, don't use
the broken "Reply" link at the bottom of the article. Click on
"show options" at the top of the article, then click on the
"Reply" at the bottom of the article headers." - Keith Thompson


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Seek xpath expression where an attribute name is a regular expression GIMME XML 3 12-29-2008 03:11 PM
C/C++ language proposal: Change the 'case expression' from "integral constant-expression" to "integral expression" Adem C++ 42 11-04-2008 12:39 PM
C/C++ language proposal: Change the 'case expression' from "integral constant-expression" to "integral expression" Adem C Programming 45 11-04-2008 12:39 PM
Matching abitrary expression in a regular expression =?iso-8859-1?B?bW9vcJk=?= Java 8 12-02-2005 12:51 AM
Dynamically changing the regular expression of Regular Expression validator VSK ASP .Net 2 08-24-2003 02:47 PM



Advertisments