Lifelesspeople.com

 Forum FAQsForum FAQs  Knowledge BaseKnowledge Base  RulesRules   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   HostingHosting   RegisterRegister 
 DonateDonate   WikiWiki   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

string search code

 
Lifelesspeople.com Forum Index -> Techy Turf
Post new topic   Reply to topic View previous topic :: View next topic  
Author Message
Tuomas
.::Dead Boy::.


Joined: 14 Jun 2004
Posts: 842
Location: Over The Hills And Far Away

PostPosted: Tue May 06, 2008 4:44 pm    Post subject: string search code Reply with quote

okay, i need an algorithm to split the following string:
Quote:

Coronel C. Title. Magazine Title [Serial on line] 2001;73(1):5-10. Avaidable in: URL:http://bvs.sld.cu/revistas/ped/vol73_1_01/ped01100.pdf.
Checked Abril 2, 2002.


what i need is to split the string into the following parts:
- Authors (in this case: Coronel C)
- Article Title (in this case: Title)
- Magazine Title (in this case: Magazine Title)
- Year (in this case: 2001)
- Volume (in this case: 73)
- Number (in this case: 1)
- Pages (in this case: 5-10)
- URL (in this case: http://bvs.sld.cu/revistas/ped.....01100.pdf)
- Checked (in this case: Abril 2, 2002)

i thought to split the strings on the "." wich separate almost every part of the context, but then if there's a title that contains a "." then the algorithm would not work....

don't know if i made myself clear, but i sure hope you could understand the problem...
any suggestion is welcome...

regards Very Happy
_________________
I'm but a poet who failed his best play
a dead boy who failed to write an ending to each of his poems...
Longest thread ever Wink
Back to top
 
linuxdoctor
Infallible Persona


Joined: 23 Apr 2005
Posts: 1247
Location: Ottawa, Canada

PostPosted: Tue May 06, 2008 7:31 pm    Post subject: Reply with quote

Language?
_________________
Misanthrope: someone who realizes that humans really are as stupid as they appear.

If you think I'm 'politically' incorrect you have the wrong politics.
Back to top
 
mcwkm
Grandmaster Poster


Joined: 30 Mar 2005
Posts: 318
Location: ct

PostPosted: Tue May 06, 2008 7:36 pm    Post subject: Reply with quote

Sorry to not answer your question but isn't this the kind of thread that would belong in the programming discussion forum that was recently removed?
Back to top
 
linuxdoctor
Infallible Persona


Joined: 23 Apr 2005
Posts: 1247
Location: Ottawa, Canada

PostPosted: Wed May 07, 2008 6:02 am    Post subject: Reply with quote

Whatever happened to that? And what about the Mad Scientist's Laboratory where we could talk about math and science? The Twitter page says that on April 27 a number of topics were removed that were deemed to be the "least used." The programming topic was quite active, I thought, and was deleted while "Our Oratory," which is hardly active at all, remained.

Never mind. That is off topic for this thread too.
_________________
Misanthrope: someone who realizes that humans really are as stupid as they appear.

If you think I'm 'politically' incorrect you have the wrong politics.
Back to top
 
Tuomas
.::Dead Boy::.


Joined: 14 Jun 2004
Posts: 842
Location: Over The Hills And Far Away

PostPosted: Sat May 10, 2008 10:50 pm    Post subject: Reply with quote

language is not important, c/c++,php, python, perl, whatever suits you better, so... what i need is the algorithm... Smile
_________________
I'm but a poet who failed his best play
a dead boy who failed to write an ending to each of his poems...
Longest thread ever Wink
Back to top
 
LP-SolidRaven
Dictator of the Dump


Joined: 06 Jun 2004
Posts: 7124
Location: The cheese is made out of moon

PostPosted: Tue May 13, 2008 11:10 am    Post subject: Reply with quote

Tuomas wrote:
language is not important, c/c++,php, python, perl, whatever suits you better, so... what i need is the algorithm... Smile

well that depends on the language ironically. In terms of speed you're probably best of using a regular expression library in C/C++. If you want it done easy just go for REGEX in PHP though Smile
_________________
Quote:

<bart416> I just realized something
<bart416> we celebrate the fact that this piece of rock made one rotation around a glowing ball of plasma that is kept together due to its own gravity well
<njsg> HAPPY NEW YEAR
<Easter> ^^
Back to top
 
Tuomas
.::Dead Boy::.


Joined: 14 Jun 2004
Posts: 842
Location: Over The Hills And Far Away

PostPosted: Wed May 14, 2008 3:23 pm    Post subject: Reply with quote

yep i though of using a regex, yet i'm not that good with regular expressions, could you point me in the right direction?
_________________
I'm but a poet who failed his best play
a dead boy who failed to write an ending to each of his poems...
Longest thread ever Wink
Back to top
 
Display posts from previous:   
Post new topic   Reply to topic    Lifelesspeople.com Forum Index -> Techy Turf All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Home | Hosting | News | Forum | Links | System Status | About | Archive | Donate ]
Powered by phpBB © 2001, 2002 phpBB Group
All trademarks and copyrights on this page are owned by their respective owners. Posts and comments are owned by the poster. Everything else © 2001 - 2007 Lifelesspeople.com