Re: Converting a tuple to a list


Gabriel Ibanez wrote: > Hi all .. > > I'm trying to using the map function to convert a tuple to a list, without > success. > > I would like to have a lonely line that performs the same ...
Posted On: Sunday 11th of November 2012 10:41:07 PM Total Views:  47
View Complete with Replies

RELATED TOPICS OF Python Programming PROGRAMMING LANGUAGE




SWIG Python undefined reference

I went through the SWIG tutorial for the example named "simple". I managed to get to the first step, creating example_wrap.c using swig, and doing: "gcc -fpic -c example_wrap.c -IC:\python24\include " to create example_wrap.o But when I needed to ...
VIEWS ON THIS POST

154

Posted on:

Sunday 11th November 2012
View Replies!

nntplib retrieve news://FULL_URL

So I have established a connection to an nntp server and I am retrieving articles to other articles on the server such as news://newsclip.ap.org/D8L4MFAG0@news.ap.org Now I am wondering how I query for that article based off of the url I ...
VIEWS ON THIS POST

91

Posted on:

Sunday 11th November 2012
View Replies!

Re: ioctl, pass buffer address, howto?

En Fri, 25 Apr 2008 09:30:56 -0300, Neal Becker escribi: > I need an ioctl call equivalent to this C code: > > my_struct s; > s.p = p; << a pointer to an array of char > s.image_size ...
VIEWS ON THIS POST

100

Posted on:

Sunday 11th November 2012
View Replies!

ioctl, pass buffer address, howto?

I need an ioctl call equivalent to this C code: my_struct s; s.p = p; << a pointer to an array of char s.image_size = image_size; return (ioctl(fd, xxx, &s)); I'm thinking to use python array for the array of ...
VIEWS ON THIS POST

102

Posted on:

Sunday 11th November 2012
View Replies!

Re: Partition list with predicate

Jared Grubb wrote: > That almost works, except that a predicate can have "memory". For > example, the predicate could be "extract every other object", which > doesn't care about the value of the object (so you cant remove them ...
VIEWS ON THIS POST

74

Posted on:

Sunday 11th November 2012
View Replies!

Re: Partition list with predicate

Jared Grubb wrote: > I want a function that removes values from a list if a predicate > evaluates to True. The best I could come up with is: Have a look at the itertools module, and the ifilter function ...
VIEWS ON THIS POST

93

Posted on:

Sunday 11th November 2012
View Replies!

why objects of old style classes are instances of 'object'

Q: from the subject, why objects of old style classes are instances of 'object' >>> class a() ass >>> A=a() >>> isinstance(A,object) True I would expect False Thx, Andy...
VIEWS ON THIS POST

95

Posted on:

Sunday 11th November 2012
View Replies!

Database vs Data Structure?

I'm working on a web application where each user will be creating several "projects" in there account, each with 1,000-50,000 objects. Each object will consist of a unique name, an id, and some meta data. The number of objects ...
VIEWS ON THIS POST

69

Posted on:

Sunday 11th November 2012
View Replies!

Opposite of repr() (kind of)

, How can I turn a string into a callable object/function I have a = 'len', and I want to do: if callable(eval(a)): print "callable", but that doesn't quite work the way I want.
VIEWS ON THIS POST

81

Posted on:

Sunday 11th November 2012
View Replies!

Re: Any reliable obfurscator for Python 2.5

En Sun, 20 Apr 2008 10:32:36 -0300, Banibrata Dutta escribi: > On 4/20/08, Gabriel Genellina wrote: >> >> En Sun, 20 Apr 2008 01:55:51 -0300, Banibrata Dutta < >> banibrata.dutta@gmail.com > escribi: >> >> > Wanted to check ...
VIEWS ON THIS POST

77

Posted on:

Sunday 11th November 2012
View Replies!

insert python script in current script

I was wondering is there any way to do this: I have written a class in python and __init__ goes like this: def __init__(self): self.name = 'jack' self.age = 50 import data now here there is data.py in the same ...
VIEWS ON THIS POST

114

Posted on:

Sunday 11th November 2012
View Replies!

Database vs Data Structure?

I'm working on a web application where each user will be creating several "projects" in there account, each with 1,000-50,000 objects. Each object will consist of a unique name, an id, and some meta data. The number of objects ...
VIEWS ON THIS POST

72

Posted on:

Sunday 11th November 2012
View Replies!

Rounding a number to nearest even

The built-in function round( ) will always "round up", that is 1.5 is rounded to 2.0 and 2.5 is rounded to 3.0. If I want to round to the nearest even, that is my_round(1.5) = 2 # As expected my_round(2.5) ...
VIEWS ON THIS POST

84

Posted on:

Sunday 11th November 2012
View Replies!

How to know if a module is thread-safe

I recently tried to use the subprocess module within a threading.Thread class, but it appears the module is not thread-safe. What is the policy of python regarding thread-safety of a module ...
VIEWS ON THIS POST

80

Posted on:

Sunday 11th November 2012
View Replies!

ikaaro 0.20.5 released

This is a Content Management System built on Python & itools, among other features ikaaro provides: - content and document management (index&search, metadata, etc.) - multilingual user interfaces and content - high level modules: wiki, forum, tracker, etc. The layout ...
VIEWS ON THIS POST

103

Posted on:

Sunday 11th November 2012
View Replies!

Creating arithmetic sequences

I wrote the code below to create simple arithmetic sequences that are iter-able I.e., this would basically combine the NUMPY arange(start,end,step) to range(start,end), with step not necessarily an integer. The code below is in its simplest form and I want ...
VIEWS ON THIS POST

65

Posted on:

Sunday 11th November 2012
View Replies!

Re: Interesting timing issue I noticed

> I've written up a stripped down version of the code. I apologize for the bad > coding; I am in a bit of a hurry. > > import random > import sys > import time > > sizeX = ...
VIEWS ON THIS POST

76

Posted on:

Sunday 11th November 2012
View Replies!

Boa: howto make child windows really child

i just started using Boa constructor, but, i dont like child windows floatin,g on my desktop. how can i make all child windows of boa all together, docked in one parent boa window... i found in preferences, general, childFrameStyle, i ...
VIEWS ON THIS POST

156

Posted on:

Sunday 11th November 2012
View Replies!

pty.spawn directs stderr to stdout

using pty.spawn() it seems that stderr output of the spawned process is directed to stdout. Is there a way to keep stderr separate and only direct stdin and stdout to the pty TIA, w best regards, Wilbert Berendsen -- ...
VIEWS ON THIS POST

251

Posted on:

Sunday 11th November 2012
View Replies!

Re: Data structure recommendation?

On Apr 7, 3:58pm, Steve Holden wrote: > > I believe the best way to implement this would be a binary search > (bisect) on the actual times, which would be O(log N). bisect is definitely the way to ...
VIEWS ON THIS POST

200

Posted on:

Sunday 11th November 2012
View Replies!