"Frank Millman" wrote in message
news:lgbe6g$j9o$1...@ger.gmane.org...
>
>
> To recap my basic setup, I have machine A which holds the source
> directory, machine B which is used to edit the program, and machines B and
> C which are both used to run the program.
>
> Initially, to prove that I u
On Thu, Mar 20, 2014 at 5:48 PM, Frank Millman wrote:
> One thing still confuses me. Over the lifetime of a project, there could be
> many thousands of changesets. Some of those could be tagged as 'major
> releases'. Someone wishing to clone the project from scratch may want to
> start from the la
北冰洋 wrote:
> I just wrote a sample like this:
> testPy/
> __init__.py
> client.py
> SoamFactory.c
> SoamFactory.so
> soamapi.py
> sample/testP.py
> export PYTHONPATH=$(TEST_LOCATION):$(TEST_LOCATION)/testPy
> I found that soamapi was imported
Peace writes:
> ...
> The serial number field always remains empty even though I enter from the GUI
> and the receiveSerialNumber function is called and I explicitly initialize it
> to the variable in the model.
> I'm trying to save the state of the program so that next time I open the
> applic
Hi guys,
Is there a difference between accessing decorators via '@' symbol and
hard coding that ? esp when the function passed to the decorator is a
recursive one?
See attachments
result from deco_with@ is
1 1 0 1 1 0 1 1 0
result from deco_without@ is
1 1 2 3 5 8 13 21 34
1 1 0 3 5 0 13 21 0
muru kessan wrote:
> Is there a difference between accessing decorators via '@' symbol and
> hard coding that ? esp when the function passed to the decorator is a
> recursive one?
The difference is not the decorator but the recursive function call.
Consider
Case 1:
@deco
def f():
...
Peter Otten <__pete...@web.de> Wrote in message:
>
> In your code change
>
> fib1 = isOddMy(fib)
>
> to
>
> fib = isOddMy(fib)
>
> and the without@ version will produce the same output as the with@ version.
>
>
I expect that one more thing is needed, since the above is inside
a functio
What is PyDev?
---
PyDev is an open-source Python IDE on top of Eclipse for Python, Jython and
IronPython development.
It comes with goodies such as code completion, syntax highlighting, syntax
analysis, code analysis, refactor, debug, interactive console, etc.
Details on
Dave Angel wrote:
> Peter Otten <__pete...@web.de> Wrote in message:
>
>>
>> In your code change
>>
>> fib1 = isOddMy(fib)
>>
>> to
>>
>> fib = isOddMy(fib)
>>
>> and the without@ version will produce the same output as the with@
>> version.
>>
>>
>
> I expect that one more thing is need
Hi,
This might sound weird, but is there a limit how many dictionaries a
can create/use in a single script?
My reason for asking is I split a 2-column-csv (phone#, ref#) file into
a dict and am trying to put duplicated phone numbers with different ref
numbers into new dictionaries. The scrip
ishish wrote:
> This might sound weird, but is there a limit how many dictionaries a
> can create/use in a single script?
No.
> My reason for asking is I split a 2-column-csv (phone#, ref#) file into
> a dict and am trying to put duplicated phone numbers with different ref
> numbers into new
In ishish
writes:
> The script [...] only creates batch1.csv.
If the script only creates batch1.csv, that means Batch2 and Batch3 must
be empty.
> for k, v in myDict.items():
> if Batch1.has_key(k):
> if k in Batch2.has_key(k):
> Batch3[k] = v
>
Please don't leave new questions in an existing thread, and
especially without changing subject line. Compose a new message
with meaningful subject line.
ishish Wrote in message:
> Hi,
>
> This might sound weird, but is there a limit how many dictionaries a
> can create/use in a single scr
Thanks Peter for the fast response, but the prob is solved. My
colleague just verbally slapped me because a dict SHOULDN'T have
duplicate keys...
I change it around to duplicate values and it works fine
I think I need coffee now... lots of it.
--
https://mail.python.org/mailman/listinfo/pyt
Dumb noob questions:
I've installed python 3.3 on my Slack box, which by default comes with
python 2.7. I know how to fire up the different IDLE environments,
but how do I differentiate between the scripts? IOW, up till now,
I've used .py on all my 2.7 files. How do I know not to run a .py in
notbob :
> I've installed python 3.3 on my Slack box, which by default comes with
> python 2.7. I know how to fire up the different IDLE environments, but
> how do I differentiate between the scripts? IOW, up till now, I've
> used .py on all my 2.7 files. How do I know not to run a .py in
> python
On 2014-03-20, Marko Rauhamaa wrote:
> That's a bit of a sore spot.
>
> On a linux box, the initial line of the script indicates the
> interpreter:
>
>#!/usr/bin/env python2
>
> for Python 2.x
>
>#!/usr/bin/env python3
>
> for Python 3.x.
>
> All tutorials will tell you to start it with
>
On 3/20/14 9:58 AM, notbob wrote:
I've installed python 3.3 on my Slack box, which by default comes with
python 2.7. I know how to fire up the different IDLE environments,
but how do I differentiate between the scripts?
hi notbob, the two (or more) IDLE environments run very nicely
side-by-s
On Thu, Mar 20, 2014 at 11:00 AM, notbob wrote:
> Ahhh! now a shabang I understand. So, I guess the only way, short
> of looking at the actual file, is to include the version in the
> filename. Can I safely assume I can run all 2.7 files w/o a shebang
> (which I have not, so far, and was won
On 2014-03-20, Zachary Ware wrote:
> If you're specifying the interpreter in your command (by calling
> "python .py", etc), the shebang won't mean anything
> anyway.
DOH!
I was following you, fine, until that last sentence. Then how should
I invoke the scripts? as your example is exactly
On 2014-03-20, Mark H Harris wrote:
> not) there really is no problem. The reason is that the .pyc files
> created for python2.x are only used by python2.
Lordy, what hath I wrought!? ;)
What the heck is a .pyc file and how are they created? Actually, I
can see it's a compiled binary, but
On Fri, Mar 21, 2014 at 4:23 AM, notbob wrote:
> On 2014-03-20, Mark H Harris wrote:
>
>> not) there really is no problem. The reason is that the .pyc files
>> created for python2.x are only used by python2.
>
> Lordy, what hath I wrought!? ;)
>
> What the heck is a .pyc file and how are they cr
On Fri, Mar 21, 2014 at 4:10 AM, notbob wrote:
> On 2014-03-20, Zachary Ware wrote:
>
>> If you're specifying the interpreter in your command (by calling
>> "python .py", etc), the shebang won't mean anything
>> anyway.
>
> DOH!
>
> I was following you, fine, until that last sentence. Then how s
On 3/20/14 12:23 PM, notbob wrote:
What the heck is a .pyc file and how are they created? Actually, I
can see it's a compiled binary, but I where did it come from?
The world according to me: python is an interpreter (vs compiler) which
converts your source code into tokens and then into a
Chris Angelico :
> Nowadays they'll be pushed away into a separate directory, which makes
> them easier for you to ignore. This is a good thing.
Still, I don't think Python should go and soil my directories without an
explicit permission.
Marko
--
https://mail.python.org/mailman/listinfo/pytho
Mark H Harris :
> If you wanted to you could run your python scripts from the .pyc file
> alone. In other words, you may import as long as the .pyc file exists
> and the source does not need to be there. Some folks use this (not
> recommended) trick to hide or obfuscate their source from their
> u
On 03/20/2014 10:10 AM, notbob wrote:
On 2014-03-20, Zachary Ware wrote:
If you're specifying the interpreter in your command (by calling
"python .py", etc), the shebang won't mean anything
anyway.
DOH!
I was following you, fine, until that last sentence. Then how should
I invoke the script
Portable Python 2.7 for Windows, the Python application have dependency on
ssdeep-2.10, which is a binary exe.
The ssdeep (libfuzzy) installation example was shown for Linux platform only:
a) libfuzzy can be installed via apt-get:
$ sudo apt-get install libfuzzy2
b) to install libfuzzy
On Thursday, March 20, 2014 1:20:03 AM UTC-7, dieter wrote:
> Peace <> writes:
>
> > ...
>
> > The serial number field always remains empty even though I enter from the
> > GUI and the receiveSerialNumber function is called and I explicitly
> > initialize it to the variable in the model.
>
> >
On 3/20/14 1:47 PM, Marko Rauhamaa wrote:
Mark H Harris :
If you wanted to you could run your python scripts from the .pyc file
alone. In other words, you may import as long as the .pyc file exists
and the source does not need to be there. Some folks use this (not
recommended) trick to hide or
On 20/03/2014 15:21, Marko Rauhamaa wrote:
notbob :
I've installed python 3.3 on my Slack box, which by default comes with
python 2.7. I know how to fire up the different IDLE environments, but
how do I differentiate between the scripts? IOW, up till now, I've
used .py on all my 2.7 files. How
In notbob writes:
> On 2014-03-20, Zachary Ware wrote:
> > If you're specifying the interpreter in your command (by calling
> > "python .py", etc), the shebang won't mean anything
> > anyway.
> DOH!
> I was following you, fine, until that last sentence. Then how should
> I invoke the scri
Le 20/03/2014 16:21, Marko Rauhamaa a écrit :
> All tutorials will tell you to start it with
>
>#!/usr/bin/env python
>
> which will start python2 on all (?) existing linux distros, but is
> expected to start python3 within the next decade.
With Arch-Linux, python is python3...
--
https:
On 3/20/14 12:47 PM, Marko Rauhamaa wrote:
I've seen it done, but at least in those Python 2 days the pyc format
changed between minor releases of Python, so Python itself had to be
shipped with the pyc files.
hi Marko, yeah, I have not done this; being that the concept is contrary
to my princ
On 3/20/2014 11:21 AM, Marko Rauhamaa wrote:
On a linux box, the initial line of the script indicates the
interpreter:
#!/usr/bin/env python2
for Python 2.x
#!/usr/bin/env python3
for Python 3.x.
All tutorials will tell you to start it with
#!/usr/bin/env python
which will sta
I am currently running code for a program called HotNet
(https://github.com/raphael-group/hotnet)
In its simpleRun.py file, there is a place to insert a file path to be run.
parser.add_argument('-mf', '--infmat_file', required=True,
help='Path to .mat file containing inf
On Thu, Mar 20, 2014 at 2:55 PM, wrote:
> File "simpleRun.py", line 29
> help= ~/home/lai/Downloads/influence_matrix_files/hprd_inf_.mat)
>^
> SyntaxError: invalid syntax
You need quotes around the filename. It's a string literal.
Skip
--
https://mail.python.org/mailman/listinf
Hi Skip!
Thank you so much for the response. When I put quotes around the file name I
receive this output.
simpleRun.py: error: argument -mf/--infmat_file is required
--
https://mail.python.org/mailman/listinfo/python-list
Alan Meyer :
> I presume it would still be a good idea to test both python
> interpreters against any script that you didn't knowingly write with a
> feature that will only work in one of the two python versions.
>
> If it works fine in both - and many will, then use:
>
> #!/usr/bin/env pytho
On 3/20/14 2:53 PM, Alan Meyer wrote:
#!/usr/bin/env python
Only use the "python2" or "python3" versions if you really have a reason
to do so.
It gets tricky for distribution (you need docs for your distros, imho)
because #!/usr/bin/env python means different things on different
systems.
On Thu, Mar 20, 2014 at 3:08 PM, wrote:
> simpleRun.py: error: argument -mf/--infmat_file is required
I think you are misinterpreting the actual purpose of the
parser_add_argument() call. It's telling you that *on the command
line* you can specify it using either
-mf some-file-name
or
--infma
On 20/03/2014 20:08, Marko Rauhamaa wrote:
Alan Meyer :
I presume it would still be a good idea to test both python
interpreters against any script that you didn't knowingly write with a
feature that will only work in one of the two python versions.
If it works fine in both - and many will, th
roy.snuff...@gmail.com wrote:
> I am currently running code for a program called HotNet
> (https://github.com/raphael-group/hotnet)
>
> In its simpleRun.py file, there is a place to insert a file path to be
> run.
>
> parser.add_argument('-mf', '--infmat_file', required=True,
>
On 3/20/14 3:07 PM, Eric Jacoboni wrote:
Le 20/03/2014 16:21, Marko Rauhamaa a écrit :
All tutorials will tell you to start it with
#!/usr/bin/env python
which will start python2 on all (?) existing linux distros, but is
expected to start python3 within the next decade.
With Arch-Linux
On 3/20/14 4:08 PM, Marko Rauhamaa wrote:
Alan Meyer :
I presume it would still be a good idea to test both python
interpreters against any script that you didn't knowingly write with a
feature that will only work in one of the two python versions.
If it works fine in both - and many will, the
Mark Lawrence :
> The starter is 2to3 which had been in the standard library for what
> seems like an eternity to me.
No problem there. It helps you transition from python2 to python3.
However, python3 is here and you should be able to write genuine python3
code with the appropriate bytes and st
On Thu, Mar 20, 2014 at 8:21 AM, Marko Rauhamaa wrote:
> notbob :
>
>> I've installed python 3.3 on my Slack box, which by default comes with
>> python 2.7. I know how to fire up the different IDLE environments, but
>> how do I differentiate between the scripts? IOW, up till now, I've
>> used .py
On Thu, Mar 20, 2014 at 3:30 PM, Marko Rauhamaa wrote:
> I must say, though, that Python3 destroyed "print" forever for me. To
> avoid nausea, I write sys.stdout.write() in all Python3 code.
To each their own :). I can't stand using 'print' as a statement.
It's a very nice trick to be able to wr
Ned Batchelder :
> Plenty of people have adopted a dual-support strategy, with one code
> base that supports both Python 2 and Python 3. The six module can help
> a great deal with this.
I wonder how easy the resulting code is to the eyes and how easy it is
for the casual maintainer to accidental
On 20/03/2014 20:30, Marko Rauhamaa wrote:
Mark Lawrence :
The starter is 2to3 which had been in the standard library for what
seems like an eternity to me.
No problem there. It helps you transition from python2 to python3.
However, python3 is here and you should be able to write genuine pyt
Dan Stromberg :
> Actually, I formerly used /usr/bin/env, but have recently (within the
> last couple of years) stopped.
>
> This is because the env trick doesn't play nicely with top IME. Also,
> it's a trick.
I'm not sure I like it either, but it's a standard idiom in Pythonland.
Marko
--
ht
On 3/20/14 4:42 PM, Marko Rauhamaa wrote:
Ned Batchelder :
Plenty of people have adopted a dual-support strategy, with one code
base that supports both Python 2 and Python 3. The six module can help
a great deal with this.
I wonder how easy the resulting code is to the eyes and how easy it is
Mark Lawrence :
> On 20/03/2014 20:30, Marko Rauhamaa wrote:
>> I must say, though, that Python3 destroyed "print" forever for me. To
>> avoid nausea, I write sys.stdout.write() in all Python3 code.
>
> Not for me, I was using from __future__ import print_function for
> years so got used to typing
Ned Batchelder :
> It's an extreme case, but the latest released version of coverage.py
> supports Python 2.3 through 3.3 with one code base. To do it, there's
> a compatibility layer (akin to six). Then you stay away from features
> that aren't available on all versions. In a few places, you migh
On Thu, Mar 20, 2014 at 1:59 PM, Marko Rauhamaa wrote:
> Well, with proper care, I suppose the same code base could support perl
> as well. ;)
>
Go even farther; how about C, PHP, and bash? I'm sure if you tried, you
could mix in some Python as well.
http://en.wikipedia.org/wiki/Polyglot_(comput
On 2014-03-20, Mark H Harris wrote:
> When I call python2 that means python2.7.6 /
>
> When I call python3 that means python3.3.4 /
>
> I can also call python2.7, which is 2.7.2 /
>
> You get the idea. There is no one set rule, because there are many
> distros (gnu/linux) that use python at va
On 3/20/14 4:59 PM, Marko Rauhamaa wrote:
Ned Batchelder :
It's an extreme case, but the latest released version of coverage.py
supports Python 2.3 through 3.3 with one code base. To do it, there's
a compatibility layer (akin to six). Then you stay away from features
that aren't available on al
On 2014-03-20, Ned Batchelder wrote:
> On 3/20/14 3:07 PM, Eric Jacoboni wrote:
>> With Arch-Linux, python is python3...
>>
> Yes, and they have been told many times that this was foolish and wrong,
> but it persists, much to our pain.
I've read that 2.7 is the defacto std for python (default
In <2089d20b-aa60-462f-aad0-51109849c...@googlegroups.com>
roy.snuff...@gmail.com writes:
> I am currently running code for a program called HotNet
> (https://github.com/raphael-group/hotnet)
> In its simpleRun.py file, there is a place to insert a file path to be run.
> parser.add_argument('
On 20/03/2014 20:50, Marko Rauhamaa wrote:
Mark Lawrence :
On 20/03/2014 20:30, Marko Rauhamaa wrote:
I must say, though, that Python3 destroyed "print" forever for me. To
avoid nausea, I write sys.stdout.write() in all Python3 code.
Not for me, I was using from __future__ import print_funct
On 3/20/14 4:28 PM, notbob wrote:
No wonder the latest O'Reilly book, Learning Python, 5th ed,
is 1600 pgs. I coulda swore someone sed python is easy. ;)
nb
Python is easy, but its not simple.
Python is elegant, and full of art, but it has no paucity of constructs,
types, and opportunities
On 3/20/2014 1:23 PM, notbob wrote:
What the heck is a .pyc file and how are they created?
.pyc contained compiled bytecode. They are created when, and only when,
you import a module. Imported library files are often big and stable,
so their compiled forms get cached. Top-level scripts are
On 3/20/2014 3:07 PM, John Gordon wrote:
There are two ways (at least!) to run a python script:
1. Execute the python interpreter manually, supplying the python script name
as an arugment, like so:
python myscript.py
python2 otherscript.py
python3 yetanotherscript.py
Thi
On 03/20/2014 11:10 AM, notbob wrote:
> On 2014-03-20, Zachary Ware wrote:
>
>> If you're specifying the interpreter in your command (by calling
>> "python .py", etc), the shebang won't mean anything
>> anyway.
>
> DOH!
>
> I was following you, fine, until that last sentence. Then how should
notbob :
> Weeping Chryst on the cross!!. No wonder the latest O'Reilly book,
> Learning Python, 5th ed, is 1600 pgs. I coulda swore someone sed
> python is easy. ;)
It's not that bad. There are two principal dialects: python2 and
python3. Take the oldest python version you have to support and wr
Chris Angelico wrote:
You can then offer a non-source-control means of downloading that
specific revision.
Just keep in mind the downside that you can't then
push or pull your changes directly back into the main
repository. You can generate a patch file for the
project maintainer to apply, howe
On 2014-03-20, Terry Reedy wrote:
> That must be the only one you imported.
So it is. Thank you.
nb
--
https://mail.python.org/mailman/listinfo/python-list
Ned Batchelder :
> On 3/20/14 4:59 PM, Marko Rauhamaa wrote:
>> Well, with proper care, I suppose the same code base could support perl
>> as well. ;)
>
> I'm not sure how to take this comment. I feel like you are mocking my
> choice. I wanted to make coverage.py available to as broad an audience
>
On Fri, Mar 21, 2014 at 9:19 AM, Gregory Ewing
wrote:
> Chris Angelico wrote:
>>
>> You can then offer a non-source-control means of downloading that
>> specific revision.
>
> Just keep in mind the downside that you can't then
> push or pull your changes directly back into the main
> repository. Y
On Thu, 20 Mar 2014 22:30:57 +0200, Marko Rauhamaa wrote:
> To avoid nausea, I write sys.stdout.write() in all Python3 code.
Now that's funny.
I-know-I-shouldn't-respond-to-obvious-trolling-but-I-can't-help-myself-ly
yrs,
--
Steven D'Aprano
--
https://mail.python.org/mailman/listinfo/python
On 20/03/2014 22:23, Marko Rauhamaa wrote:
Ned Batchelder :
On 3/20/14 4:59 PM, Marko Rauhamaa wrote:
Well, with proper care, I suppose the same code base could support perl
as well. ;)
I'm not sure how to take this comment. I feel like you are mocking my
choice. I wanted to make coverage.py
On Fri, Mar 21, 2014 at 7:08 AM, Marko Rauhamaa wrote:
> Alan Meyer :
>
>> I presume it would still be a good idea to test both python
>> interpreters against any script that you didn't knowingly write with a
>> feature that will only work in one of the two python versions.
>>
>> If it works fine
Hello. I want to use a c library. It is a complete graphic widget set.
Here code working. But i have problem with the callback function. The callback
is executed while ClikOnForm is executed but i get a error message (see after
code )
_
On Fri, Mar 21, 2014 at 9:23 AM, Marko Rauhamaa wrote:
> Ned Batchelder :
>> On 3/20/14 4:59 PM, Marko Rauhamaa wrote:
>>> Well, with proper care, I suppose the same code base could support perl
>>> as well. ;)
>>
>> I'm not sure how to take this comment. I feel like you are mocking my
>> choice.
On 3/20/14 6:16 PM, fienspr...@gmail.com wrote:
def TheProc(c_int): fpgui.fpgFormWindowTitle(0, 'Boum')
return 0
TheProcF = CMPFUNC(TheProc)
Traceback (most recent call last): File "_ctypes/callbacks.c",
line 314, in 'calling callback function' TypeError: TheProc() takes
exactly 1 argument
> Give the function call its required argument and the error will go
>
> away... well, at least that one.
Yep, many thanks for the answer.
But... im totally beginner with Python.
I develop in Pascal and C and want to understand the basics of Python.
In concrete, what must i change in the code ?
On Friday, March 21, 2014 7:56:43 AM UTC+8, fiens...@gmail.com wrote:
> > Give the function call its required argument and the error will go
>
> >
>
> > away... well, at least that one.
>
>
>
> Yep, many thanks for the answer.
>
> But... im totally beginner with Python.
>
> I develop in Pa
Portable Python 2.7 for Windows, the Python application have dependency on
ssdeep-2.10, which is a binary exe.
The ssdeep (libfuzzy) installation example was shown for Linux platform only:
a) libfuzzy can be installed via apt-get:
$ sudo apt-get install libfuzzy2
b) to install libfuzzy
On 21/03/2014 00:16, laguna...@mail.com wrote:
Portable Python 2.7 for Windows, the Python application have dependency on
ssdeep-2.10, which is a binary exe.
The ssdeep (libfuzzy) installation example was shown for Linux platform only:
a) libfuzzy can be installed via apt-get:
$ sudo
On Thu, 20 Mar 2014 21:28:43 +, notbob wrote:
> On 2014-03-20, Mark H Harris wrote:
>
>> When I call python2 that means python2.7.6 /
>>
>> When I call python3 that means python3.3.4 /
>>
>> I can also call python2.7, which is 2.7.2 /
>>
>> You get the idea. There is no one set rule, becau
On Thu, 20 Mar 2014 16:26:39 -0400, Ned Batchelder wrote:
> On 3/20/14 3:07 PM, Eric Jacoboni wrote:
>> Le 20/03/2014 16:21, Marko Rauhamaa a écrit :
>>
>>
>>> All tutorials will tell you to start it with
>>>
>>> #!/usr/bin/env python
>>>
>>> which will start python2 on all (?) existing linux
On Thu, 20 Mar 2014 16:53:25 -0400, Ned Batchelder wrote:
> On 3/20/14 4:42 PM, Marko Rauhamaa wrote:
>> Ned Batchelder :
>>
>>> Plenty of people have adopted a dual-support strategy, with one code
>>> base that supports both Python 2 and Python 3. The six module can help
>>> a great deal with thi
On Thu, 20 Mar 2014 22:50:45 +0200, Marko Rauhamaa wrote:
> Mark Lawrence :
>
>> On 20/03/2014 20:30, Marko Rauhamaa wrote:
>>> I must say, though, that Python3 destroyed "print" forever for me. To
>>> avoid nausea, I write sys.stdout.write() in all Python3 code.
>>
>> Not for me, I was using fro
On 3/20/14 8:32 PM, Steven D'Aprano wrote:
On Thu, 20 Mar 2014 16:26:39 -0400, Ned Batchelder wrote:
On 3/20/14 3:07 PM, Eric Jacoboni wrote:
Le 20/03/2014 16:21, Marko Rauhamaa a écrit :
All tutorials will tell you to start it with
#!/usr/bin/env python
which will start python2 on a
In article <532b8f0d$0$29994$c3e8da3$54964...@news.astraweb.com>,
Steven D'Aprano wrote:
> The rule of three applies here: anything you do in three different places
> ought to be managed by a function.
I prefer the rule of two :-)
--
https://mail.python.org/mailman/listinfo/python-list
On Fri, Mar 21, 2014 at 11:32 AM, Steven D'Aprano
wrote:
> Perhaps Arch-Linux is guilty of being prematurely Python 3...
>
> I have no idea what "our pain" you are referring to, or who "our" refers
> to. In the three or five years or so since Arch-Linux moved to Python 3
> by default, I don't reca
On Fri, Mar 21, 2014 at 11:59 AM, Steven D'Aprano
wrote:
> The rule of three applies here: anything you do in three different places
> ought to be managed by a function. Printing a newline at the end of a
> line of output is *incredibly* common. Any language which fails to
> provide a print-with-n
On 3/20/14 9:06 PM, Ned Batchelder wrote:
On 3/20/14 8:32 PM, Steven D'Aprano wrote:
On Thu, 20 Mar 2014 16:26:39 -0400, Ned Batchelder wrote:
On 3/20/14 3:07 PM, Eric Jacoboni wrote:
Le 20/03/2014 16:21, Marko Rauhamaa a écrit :
All tutorials will tell you to start it with
#!/usr/bi
On 03/20/2014 05:37 PM, Steven D'Aprano wrote:
In my experience, such as it is, the hard part about writing code that
works from 2.4 to 3.4 is not the 3 versions but the 2.4 and 2.5 versions.
+1000! (yes, that's factorial ;)
--
~Ethan~
--
https://mail.python.org/mailman/listinfo/python-list
On 21Mar2014 09:34, Chris Angelico wrote:
> On Fri, Mar 21, 2014 at 9:19 AM, Gregory Ewing
> > Also, unless the project is truly ancient, the
> > whole history might not be as big as you expect.
> > The code presumably grew to its present size
> > incrementally, in an approximately monotonic
> > m
On Thu, 20 Mar 2014 23:56:43 -, wrote:
Give the function call its required argument and the error will go
away... well, at least that one.
Yep, many thanks for the answer.
But... im totally beginner with Python.
I develop in Pascal and C and want to understand the basics of Python.
In c
On Fri, Mar 21, 2014 at 12:33 PM, Cameron Simpson wrote:
> Regarding having Mercurial installed, that is very easy, and after
> you've gone (eg):
>
> hg clone https://bitbucket.org/cameron_simpson/css my-copy-of-cameron's-css
>
> (or wherever the public repository is published), you can of cours
On Fri, Mar 21, 2014 at 12:06 PM, Roy Smith wrote:
> In article <532b8f0d$0$29994$c3e8da3$54964...@news.astraweb.com>,
> Steven D'Aprano wrote:
>
>> The rule of three applies here: anything you do in three different places
>> ought to be managed by a function.
>
> I prefer the rule of two :-)
T
On Friday, March 21, 2014 2:23:25 AM UTC+5:30, Ned Batchelder wrote:
> On 3/20/14 4:42 PM, Marko Rauhamaa wrote:
> > Ned Batchelder :
> >> Plenty of people have adopted a dual-support strategy, with one code
> >> base that supports both Python 2 and Python 3. The six module can help
> >> a great de
On 3/20/2014 3:07 PM, John Gordon wrote:
There are two ways (at least!) to run a python script:
> On 21/03/2014 8:05 AM, Terry Reedy wrote:
3. [...]
"Our chief weapon is..."
--
https://mail.python.org/mailman/listinfo/python-list
Hello good people I am working on a caeser cipher program for class. However, I
ran into a problem with my outputs. Up to a certain point for example:
1. two('y', 'z')
Would give a '\x92' output instead of a 'x' output.
Currently this is my code so far:
def chartonum(ch):
return ord(ch) -
dtran...@gmail.com Wrote in message:
> Hello good people I am working on a caeser cipher program for class. However,
> I ran into a problem with my outputs. Up to a certain point for example:
>
> 1. two('y', 'z')
>
> Would give a '\x92' output instead of a 'x' output.
>
> Currently this is my
On Thu, 20 Mar 2014 21:06:24 -0400, Ned Batchelder wrote:
> In the #python IRC channel, there's a steady flow of people who run
> programs they find online, and they get a syntax error on "print", and
> we say, "Arch?" and they say, "yup".
When you install random programs you find online without
On Thursday, March 20, 2014 11:16:50 PM UTC-4, Dave Angel wrote:
> dtran...@gmail.com Wrote in message:
>
> > Hello good people I am working on a caeser cipher program for class.
> > However, I ran into a problem with my outputs. Up to a certain point for
> > example:
>
> >
>
> > 1. two('y',
On Fri, Mar 21, 2014 at 2:16 PM, Steven D'Aprano
wrote:
> I haven't seen scripts broken because "env"
> has moved, but I guess that's only a matter of time.
That usage is extremely common, and isn't it also specified by POSIX?
I think that's about as dependable as you can get.
Course, it does de
1 - 100 of 112 matches
Mail list logo