On Thu, 28 Mar 2013 21:00:44 -0700, Victor Hooi wrote:
> Is it possible to somehow test for a match, as well as do assignment of
> the re match object to a variable?
mo = expression.match(line)
if mo:
...
Many problems become trivial when we stop trying to fit everything into a
single li
On Fri, Mar 29, 2013 at 12:11 AM, Ian Kelly wrote:
> From the PEP:
>
> """
> A new function PyUnicode_AsUTF8 is provided to access the UTF-8
> representation. It is thus identical to the existing
> _PyUnicode_AsString, which is removed. The function will compute the
> utf8 representation when firs
On Thu, Mar 28, 2013 at 8:37 PM, Steven D'Aprano
wrote:
>>> I also wonder why the implementation bothers keeping a UTF-8
>>> representation. That sounds like premature optimization to me. Surely
>>> you only need it when writing to a file with UTF-8 encoding? For most
>>> strings, that will never
Chris Angelico:
But both this and your example of case conversion are, fundamentally,
iterating over the string. What if you aren't doing that? What if you
want to parse and process?
Parsing is also normally a scanning operation. If you want to
process pieces of the string based on the par
On Fri, Mar 29, 2013 at 2:34 PM, Neil Hodgson wrote:
>It doesn't horrify me - I've been working this way for over 10 years and
> it seems completely natural. You can wrap access in iterators that hide the
> byte offsets if you like. This then ensures that all operations on those
> iterators ar
On Friday, March 29, 2013 9:58:27 AM UTC+10:30, Dave Angel wrote:
> On 03/28/2013 06:11 PM, Eric Parry wrote:
>
> > On Thursday, March 28, 2013 3:06:02 PM UTC+10:30, Dave Angel wrote:
>
>
>
>
>
>
>
> >>
>
> >>
>
> >> Are you familiar with recursion? Notice the last line in the functi
On 03/28/2013 08:34 PM, Neil Hodgson wrote:
Steven D'Aprano:
Any string method that takes a starting offset requires the method to
walk the string byte-by-byte. I've even seen languages put responsibility
for dealing with that onto the programmer: the "start offset" is given in
*bytes*, not cha
On Wed, Mar 27, 2013 at 7:54 PM, 小学园PHP wrote:
> Guys,
>
> I take a project that need send request to Hadoop by curl.
> But now, the curl and pycurl can't satisfy my project. So i need use the
> powerful httplib.
I would say that `requests`
(http://docs.python-requests.org/en/latest/ ) is general
Jiewei Huang wrote:
>
>Hi the output is:
>
>[('John Cleese,Ministry of Silly Walks,421,27-Oct',), ('Stacy
>Kisha,Ministry of Man Power,1234567,17-Jan',)]
>
>how to make it to
>
>[CODE][('John Cleese', 'Ministry of Silly Walks' , '421', '27-Oct'),
>('Stacy Kisha', 'Ministry of Man Power',
On Thu, Mar 28, 2013 at 9:00 PM, Victor Hooi wrote:
> Hi,
>
> I have logline that I need to test against multiple regexes. E.g.:
>
> import re
>
> expression1 = re.compile(r'')
> expression2 = re.compile(r'')
>
> with open('log.txt') as f:
> for line in f:
>
Hi,
I have logline that I need to test against multiple regexes. E.g.:
import re
expression1 = re.compile(r'')
expression2 = re.compile(r'')
with open('log.txt') as f:
for line in f:
if expression1.match(line):
# Do something - extract
MRAB:
Implementing the regex module (http://pypi.python.org/pypi/regex) would
have been more difficult if the internal representation had been UTF-8,
because of the need to decode, and the implementation would also have
been slower for that reason.
One way to build regex support for UTF-8 i
Steven D'Aprano:
Some string operations need to inspect every character, e.g. str.upper().
Even for them, the increased complexity of a variable-width encoding
costs. It's not sufficient to walk the string inspecting a fixed 1, 2 or
4 bytes per character. You have to walk the string grabbing 1 b
On Thu, 28 Mar 2013 22:37:47 +0300, Habibutsu wrote:
> For example, we have following code:
>
> 01|def foo():
> 02|return 1
> 03|
> 04|value = foo()
> 05|
> 06|if value == 1:
> 07|print value,"- equal 1"
> 08|
> 09|if isinstance(value, int):
> 10|print val
On Fri, Mar 29, 2013 at 1:37 PM, Steven D'Aprano
wrote:
> Under what circumstances will a string be created from a wchar_t string?
> How, and why, would such a string be created? Why would Python still
> support strings containing surrogates when it now has a nice, shiny,
> surrogate-free flexible
On Fri, 29 Mar 2013 11:54:41 +1100, Chris Angelico wrote:
> On Fri, Mar 29, 2013 at 11:39 AM, Steven D'Aprano
> wrote:
>> ASCII and Latin-1 strings obviously do not have them. Nor do BMP-only
>> strings. It's only strings in the SMPs that could need surrogate pairs,
>> and they don't need them in
On 29/03/2013 00:54, Chris Angelico wrote:
On Fri, Mar 29, 2013 at 11:39 AM, Steven D'Aprano
wrote:
ASCII and Latin-1 strings obviously do not have them. Nor do BMP-only
strings. It's only strings in the SMPs that could need surrogate pairs,
and they don't need them in Python's implementation s
On Fri, Mar 29, 2013 at 12:03 PM, Mark Lawrence wrote:
> On 29/03/2013 00:54, Chris Angelico wrote:
>> Minor nitpick, btw:
>>>
>>> (in which cast wstr_length differs form length)
>>
>> Should be "in which case" and "from". Who has the power to correct
>> typos in PEPs?
>
> Sneak it in here? http:/
On 29/03/2013 00:54, Chris Angelico wrote:
Minor nitpick, btw:
(in which cast wstr_length differs form length)
Should be "in which case" and "from". Who has the power to correct
typos in PEPs?
ChrisA
Sneak it in here? http://bugs.python.org/issue13604
--
If you're using GoogleCrap™ please
On Fri, Mar 29, 2013 at 11:39 AM, Steven D'Aprano
wrote:
> ASCII and Latin-1 strings obviously do not have them. Nor do BMP-only
> strings. It's only strings in the SMPs that could need surrogate pairs,
> and they don't need them in Python's implementation since it's a full 32-
> bit implementatio
On Thu, 28 Mar 2013 12:54:20 -0700, rurpy wrote:
> Even if you personally would prefer someone to respond by calling you a
> liar, your personal preferences do not form a basis for desirable
> posting behavior here.
Whereas yours apparently are.
Thanks for the feedback, I'll take it under advise
On Thu, 28 Mar 2013 10:11:59 -0600, Ian Kelly wrote:
> On Thu, Mar 28, 2013 at 8:38 AM, Chris Angelico
> wrote:
>> PEP393 strings have two optimizations, or kinda three:
>>
>> 1a) ASCII-only strings
>> 1b) Latin1-only strings
>> 2) BMP-only strings
>> 3) Everything else
>>
>> Options 1a and 1b ar
On 28/03/2013 23:53, Dennis Lee Bieber wrote:
On Wed, 27 Mar 2013 23:12:21 -0700, Ethan Furman
declaimed the following in gmane.comp.python.general:
At some point we have to stop being gentle / polite / politically correct and
call a shovel a shovel... er, spade.
Call it an Instrum
On Fri, Mar 29, 2013 at 10:53 AM, Dennis Lee Bieber
wrote:
> On Wed, 27 Mar 2013 23:12:21 -0700, Ethan Furman
> declaimed the following in gmane.comp.python.general:
>
>>
>> At some point we have to stop being gentle / polite / politically correct
>> and call a shovel a shovel... er, spade.
>
>
On 03/28/2013 06:11 PM, Eric Parry wrote:
On Thursday, March 28, 2013 3:06:02 PM UTC+10:30, Dave Angel wrote:
Are you familiar with recursion? Notice the last line in the function
r() calls the function r() inside a for loop.
So when r() returns, you're back inside the next level up o
On 3/28/2013 4:26 PM, jmfauth wrote:
Please provide references for your assertions. I have read the unicode
standard, parts more than once, and your assertions contradict my memory.
Unicode does not stipulate, one has to cover the whole range.
I believe it does. As I remember, the recognize
Chris Angelico於 2013年3月28日星期四UTC+8上午11時40分17秒寫道:
> On Thu, Mar 28, 2013 at 2:18 PM, Ethan Furman wrote:
>
> > Has anybody else thought that [jmf's] last few responses are starting to
> > sound
>
> > bot'ish?
>
>
>
> Yes, I did wonder. It's like he and Dihedral have been trading
>
> accounts
On Thursday, March 28, 2013 3:06:02 PM UTC+10:30, Dave Angel wrote:
> On 03/27/2013 11:00 PM, Eric Parry wrote:
>
> > On Wednesday, March 27, 2013 6:28:01 PM UTC+10:30, Ulrich Eckhardt wrote:
>
> >>
>
>
> http://wiki.python.org/moin/GoogleGroupsPython >
>
> >
>
> > Thank you for your e
On Thu, Mar 28, 2013 at 2:11 PM, jmfauth wrote:
> On 28 mar, 21:29, Benjamin Kaplan wrote:
>> On Thu, Mar 28, 2013 at 10:48 AM, jmfauth wrote:
>> > On 28 mar, 17:33, Ian Kelly wrote:
>> >> On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
>> >> > The flexible string representation takes the prob
On 28/03/2013 21:11, jmfauth wrote:
On 28 mar, 21:29, Benjamin Kaplan wrote:
On Thu, Mar 28, 2013 at 10:48 AM, jmfauth wrote:
> On 28 mar, 17:33, Ian Kelly wrote:
>> On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
>> > The flexible string representation takes the problem from the
>> > other
On Fri, Mar 29, 2013 at 7:26 AM, jmfauth wrote:
> The wide build (I never used) is in my mind as correct as
> the narrow build. It "just" covers a different range in unicode
> (the whole range).
Actually it does; it covers all of the Unicode range, by using
(effectively) UTF-16. Characters that c
On 28 mar, 22:11, jmfauth wrote:
> On 28 mar, 21:29, Benjamin Kaplan wrote:
>
>
>
>
>
>
>
>
>
> > On Thu, Mar 28, 2013 at 10:48 AM, jmfauth wrote:
> > > On 28 mar, 17:33, Ian Kelly wrote:
> > >> On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
> > >> > The flexible string representation takes t
On 28 mar, 21:29, Benjamin Kaplan wrote:
> On Thu, Mar 28, 2013 at 10:48 AM, jmfauth wrote:
> > On 28 mar, 17:33, Ian Kelly wrote:
> >> On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
> >> > The flexible string representation takes the problem from the
> >> > other side, it attempts to work wit
On 3/27/2013 11:50 PM, Νίκος Γκρ33κ wrote:
I'am about to go nuts with python 3.2.3
Do you see somehtign wrong with the following statement?
cur.execute( '''SELECT hits FROM counters WHERE url = ?''', (page,) )
data = cur.fetchone()
because as you can see by visiting my webpage at http://superh
On 03/28/2013 12:54 PM, [email protected] wrote:
On 03/28/2013 01:48 AM, Steven D'Aprano wrote:
On Wed, 27 Mar 2013 22:42:18 -0700, rusi wrote:
For someone who delights in pointing out the logical errors
of others you are often remarkably sloppy in your own logic.
Of course language can be both
On Thu, Mar 28, 2013 at 10:48 AM, jmfauth wrote:
> On 28 mar, 17:33, Ian Kelly wrote:
>> On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
>> > The flexible string representation takes the problem from the
>> > other side, it attempts to work with the characters by using
>> > their representations
On 28 mar, 18:55, Chris Angelico wrote:
> On Fri, Mar 29, 2013 at 4:48 AM, jmfauth wrote:
> > If Python had imlemented Unicode correctly, there would
> > be no difference in using an "a", "é", "€" or any character,
> > what the narrow builds did.
>
> I'm not following your grammar perfectly here,
In article
,
Chris Angelico wrote:
> I'd rather this list have some vinegar than it devolve into
> uselessness. Or, worse, if there's a hard-and-fast rule about
> courtesy, devolve into aspartame... everyone's courteous in words but
> hates each other underneath. Or am I taking the analogy too f
On 03/28/2013 01:48 AM, Steven D'Aprano wrote:
> On Wed, 27 Mar 2013 22:42:18 -0700, rusi wrote:
>> More seriously Ive never seen anyone -- cause or person -- aided by
>> the use of excessively strong language.
>
> Of course not. By definition, if it helps, it wasn't *excessively* strong
> langua
Τη Πέμπτη, 28 Μαρτίου 2013 4:51:16 μ.μ. UTC+2, ο χρήστης David M Chess έγραψε:
> Νίκος Γκρ33κ
> :
>
>
>
> >> What paramstyle are you using?
>
> >
>
> >Yes it is Chris, but i'am not sure what exactly are you asking me.
>
> >Please if you cna pout it even simper for me, thank you.
>
>
>
> F
For example, we have following code:
01|def foo():
02|return 1
03|
04|value = foo()
05|
06|if value == 1:
07|print value,"- equal 1"
08|
09|if isinstance(value, int):
10|print value,"- is int"
11|else:
12|print value,"- is not int"
Task is to
Well i dont like people taking to me this way espceially when iam tryign 2 days
for something and thats changing from 2.6 => 3.2.3
I follow advice as long as i can understand whats being said to me.
So if someone wants to help by asking me to try things please do.
--
http://mail.python.org/mail
On 28/03/2013 18:37, Νίκος Γκρ33κ wrote:
Will someone help me out here please?
I suggest you take a course in diplomacy, but not one given by me :)
--
If you're using GoogleCrap™ please read this
http://wiki.python.org/moin/GoogleGroupsPython.
Mark Lawrence
--
http://mail.python.org/mailm
Em sábado, 16 de fevereiro de 2013 03h22min41s UTC, eli m escreveu:
> Any small program ideas? I would prefer to stick to command line ones. Thanks.
What about this one?
Do you know how to do the elevator simulation?
--
http://mail.python.org/mailman/listinfo/python-list
Will someone help me out here please?
--
http://mail.python.org/mailman/listinfo/python-list
On Thu, Mar 28, 2013 at 8:17 AM, wrote:
> How do I differentiate(first order and 2nd order) the following equations in
> python. I want to differentiate C wrt Q.
>
> C = (Q**3)-15*(Q**2)+ 93*Q + 100
"""
Years ago, when I actually worked for a living, I would have
done something like this:
"""
On Fri, Mar 29, 2013 at 4:48 AM, jmfauth wrote:
> If Python had imlemented Unicode correctly, there would
> be no difference in using an "a", "é", "€" or any character,
> what the narrow builds did.
I'm not following your grammar perfectly here, but if Python were
implementing Unicode correctly,
On 28 mar, 17:33, Ian Kelly wrote:
> On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
> > The flexible string representation takes the problem from the
> > other side, it attempts to work with the characters by using
> > their representations and it (can only) fails...
>
> This is false. As I've
Like you werent of any help
--
http://mail.python.org/mailman/listinfo/python-list
On Fri, 29 Mar 2013 02:25:26 +1100, Chris Angelico wrote:
> On Fri, Mar 29, 2013 at 2:20 AM, Νίκος Γκρ33κ
> wrote:
>> PLEASE GIVE ME A CLUE ABOUT THIS SITUATION.
>>
>> EVEN JAILED SHELL ACCESS SAYS ITS OKEY BUT I CNA ONLY SEE A BLANK PAGE
>> NOT EVEN AN INTERNAL SERVER ERROR.
>
> Quit shouting.
On Fri, Mar 29, 2013 at 4:11 AM, Jussi Piitulainen
wrote:
> Jussi Piitulainen writes:
>
>> [email protected] writes:
>>
>> > I want to print the individual numbers of a large number using
>> > division and modulus division.
>> >
>> > For example:
>> >
>> > Enter a positive integer: 54321
>> > 5
>>
On Fri, Mar 29, 2013 at 4:03 AM, Jussi Piitulainen
wrote:
> def print_digits(num):
>left, last = divmod(num, 10)
>if left < 0: print the digits of left
>print(last)
>
> How do you print the digits of left? With print_digits. Why does it
> work? Because you only call print_digits again
Jussi Piitulainen writes:
> [email protected] writes:
>
> > I want to print the individual numbers of a large number using
> > division and modulus division.
> >
> > For example:
> >
> > Enter a positive integer: 54321
> > 5
> > 4
> > 3
> > 2
> > 1
>
> Those numbers are called the digits of th
On Fri, Mar 29, 2013 at 3:55 AM, jmfauth wrote:
> Assume you have a set of integers {0...9} and an operator,
> let say, the addition.
>
> Idea.
> Just devide this set in two chunks, {0...4} and {5...9}
> and work hardly to optimize the addition of 2 operands in
> the sets {0...4}.
>
> The problems
[email protected] writes:
> I want to print the individual numbers of a large number using
> division and modulus division.
>
> For example:
>
> Enter a positive integer: 54321
> 5
> 4
> 3
> 2
> 1
Those numbers are called the digits of the large number.
With divmod(54321, 10) you get both the
Chris,
Your problem with int/long, the start of this thread, is
very intersting.
This is not a demonstration, a proof, rather an illustration.
Assume you have a set of integers {0...9} and an operator,
let say, the addition.
Idea.
Just devide this set in two chunks, {0...4} and {5...9}
and work
On Thu, Mar 28, 2013 at 7:34 AM, jmfauth wrote:
> The flexible string representation takes the problem from the
> other side, it attempts to work with the characters by using
> their representations and it (can only) fails...
This is false. As I've pointed out to you before, the FSR does not
div
On Fri, Mar 29, 2013 at 3:01 AM, Terry Reedy wrote:
> On 3/28/2013 10:38 AM, Chris Angelico wrote:
>
>> PEP393 strings have two optimizations, or kinda three:
>>
>> 1a) ASCII-only strings
>> 1b) Latin1-only strings
>> 2) BMP-only strings
>> 3) Everything else
>>
>> Options 1a and 1b are almost ide
On Thu, Mar 28, 2013 at 8:38 AM, Chris Angelico wrote:
> PEP393 strings have two optimizations, or kinda three:
>
> 1a) ASCII-only strings
> 1b) Latin1-only strings
> 2) BMP-only strings
> 3) Everything else
>
> Options 1a and 1b are almost identical - I'm not sure what the detail
> is, but there'
On Fri, Mar 29, 2013 at 2:23 AM, wrote:
> I think we can use it in 'if else' statement. something pseudocode like: if
> there is data in TBL2 for date_sub(curdate(), interval 1 day), remove the
> database data and insert new data. else insert new data into database.
>
> How can I do it?
Can y
Τη Πέμπτη, 28 Μαρτίου 2013 5:59:55 μ.μ. UTC+2, ο χρήστης Chris Angelico έγραψε:
> On Fri, Mar 29, 2013 at 2:51 AM, Νίκος Γκρ33κ wrote:
>
> > Τη Πέμπτη, 28 Μαρτίου 2013 5:25:26 μ.μ. UTC+2, ο χρήστης Chris Angelico
> > έγραψε:
>
> >> On Fri, Mar 29, 2013 at 2:20 AM, Νίκος Γκρ33κ
> >> wrote:
>
On 3/28/2013 10:38 AM, Chris Angelico wrote:
PEP393 strings have two optimizations, or kinda three:
1a) ASCII-only strings
1b) Latin1-only strings
2) BMP-only strings
3) Everything else
Options 1a and 1b are almost identical - I'm not sure what the detail
is, but there's something flagging tho
Dear Colleague,
We would like to call your attention that the deadline for abstracts submission
for the International Conference VipIMAGE 2013 - IV ECCOMAS THEMATIC CONFERENCE
ON COMPUTATIONAL VISION AND MEDICAL IMAGE PROCESSING (www.fe.up.pt/~vipimage)
to be held October 14-16, 2013, in Melia
Τη Πέμπτη, 28 Μαρτίου 2013 4:42:59 μ.μ. UTC+2, ο χρήστης Miki Tebeka έγραψε:
> > Fianlly my cgi .py script doesnt produce any more errors, i think i ahve
> > correct them but it present a blank screen
>
> > Any idea why?
>
> Please post the code to the script, otherwise we can't help you.
Can y
On Thu, Mar 28, 2013 at 7:01 AM, Steven D'Aprano
wrote:
> Any string method that takes a starting offset requires the method to
> walk the string byte-by-byte. I've even seen languages put responsibility
> for dealing with that onto the programmer: the "start offset" is given in
> *bytes*, not cha
On Fri, Mar 29, 2013 at 2:51 AM, Νίκος Γκρ33κ wrote:
> Τη Πέμπτη, 28 Μαρτίου 2013 5:25:26 μ.μ. UTC+2, ο χρήστης Chris Angelico
> έγραψε:
>> On Fri, Mar 29, 2013 at 2:20 AM, Νίκος Γκρ33κ wrote:
>>
>> > PLEASE GIVE ME A CLUE ABOUT THIS SITUATION.
>>
>> >
>>
>> > EVEN JAILED SHELL ACCESS SAYS ITS O
On 28/03/13 15:25, Wolfgang Maier wrote:
Dear all, with
a=list(range(1,11))
why (in Python 2.7 and 3.3) is this explicit for loop working:
for i in a[:-1]:
a.pop() and a
giving:
[1, 2, 3, 4, 5, 6, 7, 8, 9]
[1, 2, 3, 4, 5, 6, 7, 8]
[1, 2, 3, 4, 5, 6, 7]
[1, 2, 3, 4, 5, 6]
[1, 2, 3, 4, 5]
[1
Τη Πέμπτη, 28 Μαρτίου 2013 5:25:26 μ.μ. UTC+2, ο χρήστης Chris Angelico έγραψε:
> On Fri, Mar 29, 2013 at 2:20 AM, Νίκος Γκρ33κ wrote:
>
> > PLEASE GIVE ME A CLUE ABOUT THIS SITUATION.
>
> >
>
> > EVEN JAILED SHELL ACCESS SAYS ITS OKEY BUT I CNA ONLY SEE A BLANK PAGE NOT
> > EVEN AN INTERNAL S
Tim Chase tim.thechases.com> writes:
> it's because you're taking a snapshot copy of "a" in the middle of
> the loop. In your first example, if you change it to
>
> results = []
> for i in a[:-1]:
> results.append(a.pop() and a)
> print results
>
> you get the same thing as your list
On 28 mar, 16:14, jmfauth wrote:
> On 28 mar, 15:38, Chris Angelico wrote:
>
>
>
>
>
>
>
>
>
> > On Fri, Mar 29, 2013 at 1:12 AM, jmfauth wrote:
> > > This flexible string representation is so absurd that not only
> > > "it" does not know you can not write Western European Languages
> > > with l
Wolfgang Maier wrote:
> Dear all, with
> a=list(range(1,11))
>
> why (in Python 2.7 and 3.3) is this explicit for loop working:
> for i in a[:-1]:
> a.pop() and a
>
> giving:
> [1, 2, 3, 4, 5, 6, 7, 8, 9]
> [1, 2, 3, 4, 5, 6, 7, 8]
> [1, 2, 3, 4, 5, 6, 7]
> [1, 2, 3, 4, 5, 6]
> [1, 2, 3, 4,
On 2013-03-28 15:25, Wolfgang Maier wrote:
> Dear all, with
> a=list(range(1,11))
>
> why (in Python 2.7 and 3.3) is this explicit for loop working:
> for i in a[:-1]:
> a.pop() and a
As you discover:
> Especially, since these two things *do* work as expected:
> [a.pop() and a[:] for i in a[
On Fri, Mar 29, 2013 at 2:20 AM, Νίκος Γκρ33κ wrote:
> PLEASE GIVE ME A CLUE ABOUT THIS SITUATION.
>
> EVEN JAILED SHELL ACCESS SAYS ITS OKEY BUT I CNA ONLY SEE A BLANK PAGE NOT
> EVEN AN INTERNAL SERVER ERROR.
Quit shouting. You are asking for free help from volunteers.
At the moment, you're a
On Fri, Mar 29, 2013 at 2:14 AM, jmfauth wrote:
> As long as you are attempting to devide a set of characters in
> chunks and try to handle them seperately, it will never work.
Okay. Let's look at integers. To properly represent the Python 3 'int'
type (or the Python 2 'long'), we need to be able
I have 2 tables TBL1 and TBL2.
TBL1 has 2 columns id, nSql.
TBL2 has 3 columns date, custId, userId.
I have 17 rows in TBL1 with id 1 to 17. Each nSql has a SQL query in it.
For example nSql for
id == 1 is: "select date, pId as custId, tId as userId from TBL3"
id == 2 is: "select date, qId as cu
Dear all, with
a=list(range(1,11))
why (in Python 2.7 and 3.3) is this explicit for loop working:
for i in a[:-1]:
a.pop() and a
giving:
[1, 2, 3, 4, 5, 6, 7, 8, 9]
[1, 2, 3, 4, 5, 6, 7, 8]
[1, 2, 3, 4, 5, 6, 7]
[1, 2, 3, 4, 5, 6]
[1, 2, 3, 4, 5]
[1, 2, 3, 4]
[1, 2, 3]
[1, 2]
[1]
but the equ
PLEASE GIVE ME A CLUE ABOUT THIS SITUATION.
EVEN JAILED SHELL ACCESS SAYS ITS OKEY BUT I CNA ONLY SEE A BLANK PAGE NOT EVEN
AN INTERNAL SERVER ERROR.
[email protected] [~/www/cgi-bin]# /usr/bin/python3 metrites.py
says its ok.
--
http://mail.python.org/mailman/listinfo/python-list
On 28 mar, 15:38, Chris Angelico wrote:
> On Fri, Mar 29, 2013 at 1:12 AM, jmfauth wrote:
> > This flexible string representation is so absurd that not only
> > "it" does not know you can not write Western European Languages
> > with latin-1, "it" penalizes you by just attempting to optimize
> >
On Fri, Mar 29, 2013 at 1:51 AM, MRAB wrote:
> On 28/03/2013 12:11, Neil Hodgson wrote:
>>
>> Ian Foote:
>>
>>> Specifically, indexing a variable-length encoding like utf-8 is not
>>> as efficient as indexing a fixed-length encoding.
>>
>>
>> Many common string operations do not require indexing b
this is correct when it runs from a browser thats not the issue here othwerise
it would prodice an error.
the question is why the blank screen...
somehting with param style perhaps?
--
http://mail.python.org/mailman/listinfo/python-list
Νίκος Γκρ33κ :
>> What paramstyle are you using?
>
>Yes it is Chris, but i'am not sure what exactly are you asking me.
>Please if you cna pout it even simper for me, thank you.
For instance:
>>> import MySQLdb
>>> MySQLdb.paramstyle
'format'
FWIW and HTH,
DC
--
http://mail.python.org/mailman
On Fri, Mar 29, 2013 at 1:46 AM, Νίκος Γκρ33κ wrote:
>
Oh look, an exception traceback! In all this time of using Python,
Nikos, have you learned how to read these?
Very courteous of it to provide.
ChrisA
--
http://mail.python.org/mailman/listinfo/python-list
Τη Πέμπτη, 28 Μαρτίου 2013 4:42:59 μ.μ. UTC+2, ο χρήστης Miki Tebeka έγραψε:
> > Fianlly my cgi .py script doesnt produce any more errors, i think i ahve
> > correct them but it present a blank screen
>
> > Any idea why?
>
> Please post the code to the script, otherwise we can't help you.
who e
On 28/03/2013 12:11, Neil Hodgson wrote:
Ian Foote:
Specifically, indexing a variable-length encoding like utf-8 is not
as efficient as indexing a fixed-length encoding.
Many common string operations do not require indexing by character
which reduces the impact of this inefficiency. UTF-8 see
Τη Πέμπτη, 28 Μαρτίου 2013 4:42:59 μ.μ. UTC+2, ο χρήστης Miki Tebeka έγραψε:
> Please post the code to the script, otherwise we can't help you.
I wanted to make my website running Python 3 which is more new and bette:)
i treid to execute metrites.py via my jailed shell, please take a look if i'a
On Fri, Mar 29, 2013 at 1:39 AM, wrote:
> I want to print the individual numbers of a large number using division and
> modulus division.
>
> For example:
>
> Enter a positive integer: 54321
> 5
> 4
> 3
> 2
> 1
Python has two operators that can help here:
// for integer division - returns the
On Thu, Mar 28, 2013 at 10:39 AM, wrote:
> I want to print the individual numbers of a large number using division
> and modulus division.
>
> For example:
>
> Enter a positive integer: 54321
> 5
> 4
> 3
> 2
> 1
>
>
This looks familiar. Make the integer a string and use a for loop to
iterate ove
> Fianlly my cgi .py script doesnt produce any more errors, i think i ahve
> correct them but it present a blank screen
> Any idea why?
Please post the code to the script, otherwise we can't help you.
--
http://mail.python.org/mailman/listinfo/python-list
I want to print the individual numbers of a large number using division and
modulus division.
For example:
Enter a positive integer: 54321
5
4
3
2
1
--
http://mail.python.org/mailman/listinfo/python-list
On Fri, Mar 29, 2013 at 1:12 AM, jmfauth wrote:
> This flexible string representation is so absurd that not only
> "it" does not know you can not write Western European Languages
> with latin-1, "it" penalizes you by just attempting to optimize
> latin-1. Shown in my multiple examples.
PEP393 str
Fianlly my cgi .py script doesnt produce any more errors, i think i ahve
correct them but it present a blank screen
http://superhost.gr
Any idea why?
What should i check?
--
http://mail.python.org/mailman/listinfo/python-list
On 28 mar, 14:01, Steven D'Aprano wrote:
> On Thu, 28 Mar 2013 23:11:55 +1100, Neil Hodgson wrote:
> > Ian Foote:
>
>
> > One benefit of
> > UTF-8 over Python's flexible representation is that it is, on average,
> > more compact over a wide set of samples.
>
> Sure. And over a different set of sam
Hi:
I know this may not be the right place to post this but I found some other
PyQt questions and I am desperate.
My app is the Window class object below and I am trying to embed a
QVTKRenderWindowInteractor class called ConeWindow in its QTabWidget. First
of all running ConeWindow gives out
[email protected] writes:
> I've been working through a Python tutorial online and one of the exercises
> uses the zip command. The only problem is that the command doesn't work.
> I've read through the man page for zip and it looks like what I'm attempting
> should work, but it doesn't.
>
On 28 mar, 11:30, Chris Angelico wrote:
> On Thu, Mar 28, 2013 at 8:03 PM, jmfauth wrote:
-
> You really REALLY need to sort out in your head the difference between
> correctness and performance. I still haven't seen one single piece of
> evidence from you that Python 3.3 fails on any point
Hiya all.
it might be appropriate to imagine the remote surveillance of the color using
up-to-date methodologies when studying the line with the color remote
monitoring;
We may also notice that, everybody should applicate this type of guidelines
The hairline on the
right side of the face creat
On Thu, 28 Mar 2013 23:11:55 +1100, Neil Hodgson wrote:
> Ian Foote:
>
>> Specifically, indexing a variable-length encoding like utf-8 is not as
>> efficient as indexing a fixed-length encoding.
>
> Many common string operations do not require indexing by character
> which reduces the impact
On Thu, 28 Mar 2013 05:17:36 -0700, zingbagbamark wrote:
> How do I differentiate(first order and 2nd order) the following
> equations in python. I want to differentiate C wrt Q.
>
> C = (Q**3)-15*(Q**2)+ 93*Q + 100
For such a simple case, you don't do it with Python, you do it with
maths, and
On 28/03/2013 03:18, Ethan Furman wrote:
I wouldn't call it unproductive -- a half-dozen amusing posts followed
because of Mark's initial post, and they were a great relief from the
tedium and (dare I say it?) idiocy of jmf's posts.
--
~Ethan~
Thanks for those words. They're a tonic as I've
How do I differentiate(first order and 2nd order) the following equations in
python. I want to differentiate C wrt Q.
C = (Q**3)-15*(Q**2)+ 93*Q + 100
--
http://mail.python.org/mailman/listinfo/python-list
1 - 100 of 115 matches
Mail list logo