On 08/10/13 07:17, Chris Angelico wrote:
Who's up for some fun? Implement an XKCD-936-compliant password
generator in Python 3, in less code than this:
print(*__import__(random).sample(open(/usr/share/dict/words).read().split(\n),4))
print(imploring epsilon decamp graveyard's)
# Chosen by
On Wednesday 10 Apr 2013 14:16:23 Joe Hill wrote:
Recently I installed Python 3.3 successfully.
Yesterday - I have a bunch of PY files such as thesaurus.py, some *.p7s
files, some signature files and an index.fpickle. A total of 23 files.
Where do they come from and how do they end up as
I don't know about argparse, but if you use docopt
(http://docopt.org/) then this is easy to do with something like:
Usage:
finder.py --file myfile --dir mydir
finder.py --pattern mypattern --dir mydir
finder.py --file myfile --pattern mypattern --dir mydir
On 23 March 2013 16:04, Marco
It looks like you're using single underscores, not double: the methods
should be __init__ and __str__.
On 1 March 2013 18:35, leonardo selmi l.se...@icloud.com wrote:
hi guys
i typed the following program:
class ball:
def _init_(self, color, size, direction):
self.color = color
Have you seen http://pyraknet.slowchop.com/? It appears to do a similar thing.
On 30 January 2013 17:02, Jorge Alberto Diaz Orozco
jaoro...@estudiantes.uci.cu wrote:
I´ve tried it but it´s not reliable. Datagrams can arive disorganised or just
not arive.
Some programmers said I most use TCP,
On 28 January 2013 17:07, Wanderer wande...@dialup4less.com wrote:
Yes. I noticed this variability. I've been using the Totusoft
Lan_Speedtest.exe to test some modules. I've tested through the wifi to our
intranet and saw variations I believe do to network traffic. I also tried
peer to peer
On 24 January 2013 21:11, Oscar Benjamin oscar.j.benja...@gmail.com wrote:
l = [{'a': 'xx', 'b': 'yy', 'c': 'zz'}, {'a': 'dd', 'b': 'ee', 'c': 'ff'}]
dict(d.values()[:2] for d in l)
{'xx': 'zz', 'dd': 'ff'}
Python doesn't guarantee any ordering of items in a dictionary; {'a':
'xx', 'b': 'yy',
On 15 January 2013 07:09, llanitedave llanited...@veawb.coop wrote:
So I put the following test code in my initialization method:
# open database file
self.geologger_db = sqlite3.connect('geologger.mgc')
self.db_cursor = self.geologger_db.cursor()
self.foreign_key_status =
On 15 January 2013 15:51, llanitedave llanited...@veawb.coop wrote:
Thanks for the suggestion, Rob, but that didn't make any difference. I've
never had an issue with putting the execute object into a variable and
calling fetch on that variable.
I can accept reality if it turns out that
the
changes were.
/evangelism
On 15 January 2013 20:29, llanitedave llanited...@veawb.coop wrote:
On Tuesday, January 15, 2013 9:13:13 AM UTC-8, Rob Day wrote:
On 15 January 2013 15:51, llanitedave llanited...@veawb.coop wrote:
Thanks for the suggestion, Rob, but that didn't make any
On Sun, 2012-08-26 at 10:36 -0700, Tigerstyle wrote:
self.assertEqual(statinfo.st_size, filesize)
I'm still getting AssertionError and the error says: 100 !=b'
filesize is the character 'b' repeated one million times (the contents
of the file, in other words).
On Fri, 2012-08-24 at 12:43 -0700, Willem Krayenhoff wrote:
Any idea why print isn't working here?
You're using Python 3.2, but trying Python 2.7 syntax -
http://docs.python.org/release/3.0.1/whatsnew/3.0.html#print-is-a-function
should explain the problem adequately.
(Incidentally - you can
On 17 August 2012 14:27, Gilles nos...@nospam.com wrote:
print Content-Type: text/plain;charset=utf-8
print
Here's the problem - you're telling the browser to display in plain text.
Try 'text/html' instead.
--
Robert K. Day
robert@merton.oxon.org
--
On 16 August 2012 08:23, Pervez Mulla mullaper...@gmail.com wrote:
In HTml when user submit POST method, it calling Python code Instead
of this I wanna call perl script for sign up ..
Can you not just change the action= attribute in your form HTML attribute
to point to your Perl CGI
The list nlist inside of function xx is not the same as the variable u
outside of the function: nlist and u refer to two separate list objects.
When you modify nlist, you are not modifying u.
http://mail.python.org/mailman/listinfo/python-list
Well - that's not quite true. Before calling
I'd just create a module - called shared_utils.py or similar - and import
that in both projects. It might be a bit messy if there's no 'unifying
theme' to the module - but surely it'd be a lot less messy than your
TempDirectory class, and anyone else who knows Python will understand
'import
16 matches
Mail list logo