473,545 Members | 2,788 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

[perl-python] Python documentation moronicities (continued)

http://python.org/doc/2.4.1/lib/module-re.html
http://python.org/doc/2.4.1/lib/node114.html

---------
QUOTE
The module defines several functions, constants, and an exception. Some
of the functions are simplified versions of the full featured methods
for compiled regular expressions. Most non-trivial applications always
use the compiled form
UNQUOTE
What does a programer who wants to use regex gets out from this piece
of motherfucking irrevalent drivel?

----------
QUOTE
compile(
pattern[, flags])

Compile a regular expression pattern into a regular expression object,
which can be used for matching using its match() and search() methods,
described below.

The expression's behaviour can be modified by specifying a flags
value. Values can be any of the following variables, combined using
bitwise OR (the | operator).
UNQUOTE
What exactly is it fucking saying?

I wanted to use regex to find & replace on text. I've read in a file.
Trying to reading this fucking doc is a pain in the ass. What are these
"flags"? Do i do

re.compile(r'my pat','M') or
re.compile(r'my pat',M)
or perhaps
re.compile(r'my pat',re.M)

The M isn't a fucking variable. Why does the doc incompetently use that
term?
And what the fuck is it unclearly meant by "OR" operator with the
mother fucking bitwise jargon?

All a person reading regex really wanted is to see how to use a string
pattern and replace it with another. The fucking doc cannot be possibly
fucking worsely written.

Fuck the mother fucking coders in the IT industry.

So, is
re.compile(r'my pat','M')
re.compile(r'my pat','MULTILINE ')
equivalent?

and, by that fucking bitwise shit is it meant to say like
re.compile(r'my pat','M'|'U')
?

why cannot this piece of shit writing give a single example of usage?
and motherfucking confusedly organized, with fucking variable terms the
writer don't fucking understand, and meanwhile always trying to sound
big asshole and don't stop at masturbation by mention a regex book and
not hesitate to mention another language Perl. Fucking morons.

for a exposition of IT's fucking stupid docs and their fuckhead coders,
see:
http://xahlee.org/Periodic_dosage_di...ami_cukta.html

a cleaned up account of this post will be appended to the above
exposition.

--------

One final piece of advice here to sober up the fuckheads who are
currently offended and defiant: you want to ask yourself this question:
Can a seasoned programer, who is expert at least 2 languages, who is
also a expert at Perl and knew regex well, and who has also read the
official Python tutorial and has written at least 10 simple python
programs over a span of a month, can such a person, who have not yet
used regex in Python but now wants to use regex in Python and have just
read the doc, must he, resort to many trial and error to see exactly
what the doc is talking about?

But, can this doc be (re-)written effectively and easily so that any
programers needn't do trial'n'error post-reading?

The answer to the questions are resounding yeses, you fucking asses.

paypal me a hundred dollars and i'll rewrite the whole re doc in a few
hours.

Fuck you the standard IT morons. Excuse me for i didn't have time to
write a more coherent and detailed analysis of the stupidities of the
re doc.

Xah
xa*@xahlee.org
∑ http://xahlee.org/PageTwo_dir/more.html ☄

Jul 18 '05
75 4604
Joe Smith wrote:
Xah Lee wrote:
of motherf***ing irrevalent drivel?


I am greatly amused.
A troll impersonating Xah Lee has made xah look like a total moron.
LOL


Sorry, Joe, but why do you think this wasn't Xah?
Every detail of the post is consistent with his
recent postings.

And a secondary, but purely rhetorical, question:
how could the post have made him look like a moron
when he already looked like one?
Jul 18 '05 #11
Peter Hansen wrote:
Joe Smith wrote:
Xah Lee wrote:
of motherf***ing irrevalent drivel?


I am greatly amused.
A troll impersonating Xah Lee has made xah look like a total moron.
LOL


Sorry, Joe, but why do you think this wasn't Xah?


why do you think "Joe" and "Xah" are two different persons? ;-)

</F>

Jul 18 '05 #12
Fredrik Lundh wrote:
Peter Hansen wrote:
Joe Smith wrote:
Xah Lee wrote:

of motherf***ing irrevalent drivel?

I am greatly amused.
A troll impersonating Xah Lee has made xah look like a total moron.
LOL


Sorry, Joe, but why do you think this wasn't Xah?


why do you think "Joe" and "Xah" are two different persons? ;-)


Because Joe writes properly, and concisely. ;-)
Jul 18 '05 #13
Ivan Van Laningham wrote:
Richie Hindle wrote:

[Xah]
motherfucking ... fucking ... fucking ... fucking ... fuck ... fucking
fucking ... fucking ... mother fucking ... fucking ... piece of shit ...
motherfucking ... fucking ... fucking ... big asshole ... masturbation ...
Fucking morons ... fucking stupid ... fuckhead coders ... fuckheads ...
you fucking asses.

paypal me a hundred dollars and i'll rewrite the whole re doc in a few
hours.


Can we paypal you a hundred dollars to leave us alone? I'll pledge $10.
Are there another nine people here who'll do the same?


Why don't we pay him $100 to re-write the PERL docs?


Interestingly, Richard Hindle's message was classified as ham by my
spambayes, whereas your message was unsure. Could it be the
second-to-last word doing it? (-;

Gerrit.

--
Weather in Twenthe, Netherlands 12/04 19:55:
13.0°C wind 2.2 m/s NNW (57 m above NAP)
--
In the councils of government, we must guard against the acquisition of
unwarranted influence, whether sought or unsought, by the
military-industrial complex. The potential for the disastrous rise of
misplaced power exists and will persist.
-Dwight David Eisenhower, January 17, 1961
Jul 18 '05 #14
> why cannot this piece of shit writing give a single example of usage?
Actually, I can understand your frustration even if you should enhance
your vocabulary slightly. I often struggle with the Python
documnetation myself and I can't understand why a couple of examples
are so hard to give. When I laernt PHP I used the resources at php.net
exclusively, and that's because of the plenty of examples and the
newbie friendlyness. Recently I struggled with the regex module and
found the the documentation being close to worthless. I'm not a CS guy,
I may have a harder fight grasping concepts. The re documentation, like
much Python documentation seems to be written with other people than my
kind in mind. Luckily I found this regex howto:
http://www.amk.ca/python/howto/regex/ and that helped a lot. In
addition, Mr. Magnus Lie Hetland coincidentally posted a question on
this list that got answers that helped me out.
(http://groups-beta.google.com/group/...4c56ca66231d7f)

Jul 18 '05 #15
On Tue, 12 Apr 2005 13:06:36 +0200, Roman Neuhauser
<ne************ *************** ***@sigpipe.cz> wrote:

Unfortunately, the python community seems to bathe in the
misorganized half-documentation, see e. g.
http://marc.theaimsgroup.com/?l=pyth...3919606261&w=2
especially the reply that (as I read it) suggested reverse
engineering as a viable alternative to documentation.

As I read the reply, it was a smart-arse attempt at humour, a *PUN* on
the word "list" (mailing list versus Python list). What I would call
"introspect ion" (not "reverse engineering") was then suggested.

Moreover, both of the concepts mentioned in the quoted thread
(sequence.index () and the "in" operator) are IMESHO adequately
documented.

Do you have any examples of what you regard as "misorganiz ed
half-documentation"?

Here's a puzzle for you: Where does this list appear? What's missing?

"..., Mullender, Nagata, Ng, Oner, Oppelstrup, ..."
Jul 18 '05 #16
On 12 Apr 2005 15:06:30 -0700, "runes" <ru*********@gm ail.com> wrote:
Luckily I found this regex howto:
http://www.amk.ca/python/howto/regex/ and that helped a lot.
Luckily??? AMK's howto is pointed to by the 3rd paragraph of Section
4.2.1 of the documentation that you are dissing:

"""
A brief explanation of the format of regular expressions follows. For
further information and a gentler presentation, consult the Regular
Expression HOWTO, accessible from http://www.python.org/doc/howto/.
"""
In
addition, Mr. Magnus Lie Hetland coincidentally posted a question on
this list that got answers that helped me out.
(http://groups-beta.google.com/group/...4c56ca66231d7f)


The answers (paraphrased) were "read the [Xah-Lee-word]ing manual".
I'm glad that you RTFMed, and that it helped you. You should do so
more often.

Jul 18 '05 #17
Thank you for being so friendly!

I found the Howto through Google. Somehow I didn't see that link in the
documentation.

And please do not make any assumptions about my reading of manuals.

Jul 18 '05 #18
In comp.lang.perl. misc Xah Lee <xa*@xahlee.org > wrote:
The answer to the questions are resounding yeses, you fucking asses. paypal me a hundred dollars and i'll rewrite the whole re doc in a few
hours. Fuck you the standard IT morons. Excuse me for i didn't have time to
write a more coherent and detailed analysis of the stupidities of the
re doc.


Don't worry! Very soon, some nice men in white coats will show you
a comfortable room with soft walls in which you can write such
documentation to your hearts content.

Axel

Jul 18 '05 #19

I sympathize with you and also think there should be an "add comment" in
the Python documentation website, so that users could post their code
snippets in the relevant places.
I found the Howto through Google. Somehow I didn't see that link in the
documentation.

And please do not make any assumptions about my reading of manuals.


Jul 18 '05 #20

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
8123
by: Mark Wilson CPU | last post by:
This must be easy, but I'm missing something... I want to execute a Perl script, and capture ALL its output into a PHP variable. Here are my 2 files: ------------------------------------- test3.pl ------------------------------------- print "PERL Hello from Perl! (plain print)<br>\n"; print STDERR "PERL This is text sent to STDERR<br>\n";...
6
5934
by: John Smith | last post by:
Hello, I have a rather odd question. My company is an all java/oracle shop. We do everything is Java... no matter what it is... parsing of text files, messaging, gui you name it. My question is this... is Perl so much better at parsing text files and outputing that we would see a substantial speed increase? We process about 10 million...
3
3443
by: David F. Skoll | last post by:
Hi, I'm tearing my hair out on this one. I'm trying to embed a Perl interpreter into a C program. I need to be able to create and destroy the interpreter periodically, but will never actually have two interpreters at the same time. On Red Hat Linux 7.3 with Perl 5.6.1, the attached program segfaults. On Red Hat 9 with Perl 5.8.0, it...
1
4668
by: Julia Bell | last post by:
I would like to run the same script on two different platforms. The directory in which the script(s) will be stored is common to the two platforms. (I see the same directory contents regardless of which platform I use to access the directory.) Platform 1: perl is installed in /tps/bin/perl. CPAN modules are available Perl is also...
1
3614
by: smsabu2002 | last post by:
Hi, I am facing the build problem while installing the DBD-MySql perl module (ver 2.9008) using both GCC and CC compilers in HP-UX machine. For the Build using GCC, the compiler error is produced due to the unknown GCC compiler option "+DAportable". For the Build using CC, the preprocessor error is produced due to the recursive...
0
9734
by: Kirt Loki Dankmyer | last post by:
So, I download the latest "stable" tar for perl (5.8.7) and try to compile it on the Solaris 8 (SPARC) box that I administrate. I try all sorts of different switches, but I can't get it to compile. I need it to be compiled with threads. Anyone have any wisdom on how best to do this? Here's a transcript of my latest attempt. It's long; you...
6
2985
by: surfivor | last post by:
I may be involved in a data migration project involving databases and creating XML feeds. Our site is PHP based, so I imagine the team might suggest PHP, but I had a look at the PHP documentation for one of the Pear modules for creating XML and it didn't look like much. I've used Perl XML:Twig and I have the impression that there is more Perl...
4
3681
by: billb | last post by:
I installed a perl extension for PHP to use some perl inside my php primarily because I have perl working with oracle and not php and oracle. So I want to use my old perl scripts, and use the functionality of php. The extension uses the '$perl->eval' function. i am kind of stuck with the syntax or how to put the php variable into the perl...
0
7432
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7689
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
7943
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
5359
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5076
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3490
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
1919
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1044
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
743
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.