develooper Front page | perl.beginners | Postings from March 2002

unusual character splitting

Thread Next
From:
Lex
Date:
March 6, 2002 08:45
Subject:
unusual character splitting
Message ID:
000801c1c578$e8176800$540a040a@copernicus
Hello

I'm a student from belgium (Leuven) and i have to write a program in perl; and i have folowing problem:

i want to split a line like:

$line = 'hello, this is a test line, but what with the letter ä or ë?';

en when i split like this:

@words = split(/[^\w]+/, $lijn);

I'll get

"hello", "this", "is", "a", "test", "line", "but", "what", "with" "the", "letter" and "or"

but i won't get "ë" or "ä", 

thus is my question: which regex do i have to use so i'll get the words with diaeresis also in @words?

thanks for any help!

greetz

Alex

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About