Re: checking if two things do not equal None
> I couldn't see anyone else give this, but I like > if None not in (a, b): I did. > I am now considering: > if None not in (a,b): > or > if (a is not None) and (b is not None): However, I decided to just turn the two parameters into one (sequence), since they were logically grouped anyhow. -- https://mail.python.org/mailman/listinfo/python-list
Compiling and transporting modules/libraries in python
Hi all - I hope this is a simple question, but I've been running in circles trying to figure it out myself. Is there a good way to wrap up a library (e.g. numpy or matplotlib) so that I can use it on another machine without actually installing it? I use python at a home office and in a university computer lab, but I don't have the administrative rights to install libraries on the lab computers. It would be really nice if there were a way I could put, say, all of numpy into a file "my_numpy.pyc" and treat it as a single (large) module. thanks -Abe PS - If the answer somehow involves compileall, could you spell it out for me? I haven't been able to figure how to make compileall work for this. -- http://mail.python.org/mailman/listinfo/python-list
Re: Compiling and transporting modules/libraries in python
alex23 - Thanks for the tips. I'm using portable python and it's working great so far. I'll come back and try virtualenv if I get stuck again. - Abe -- http://mail.python.org/mailman/listinfo/python-list
Is there a way to load multiple wxhtmlwindow at the same time?
All - I'm working on a program that loads a series of web pages so the user can view them quickly one after another. I'm using python and wxhtmlwindow, and the page loading is really slow. Is there a simple way to load up the next few pages in the queue while the user is looking at the current page? thanks! - Abe PS - If the answer involves threading, can you please point me to some resources on threading in wx? I know the basics of GUI programming in wx and threading in python, but I have no idea how to put them together. -- http://mail.python.org/mailman/listinfo/python-list
Re: some pointers for a newbie
On Sun, 05 Dec 2004 02:26:48 +, Jon Mercer <[EMAIL PROTECTED]> wrote: > On the matter of IDEs, I've found that Eclipse (http://www.eclipse.org) > is amazing, although I suspect that it takes a bit of learning to get > used to it and I'm nowhere near making full use of all it can do. It has > a really useful plugin in the shape of PyDev. I strongly recommend > having a play, although at 2am on a Sunday morning it may be peripheral > to what you are trying to achieve! I'd second the suggestion to look into Eclipse if you are interested in an IDE. I'm just starting to work in OS X (G5 now, possibly a Powerbook in the future) coming from a Linux background. What I like about Eclipse is that it is cross-platform, and it also supports the other languages I've worked with in the past (Java, C/C++). PyDev seems to work pretty well. And I've seen lots of other folks developing plug-ins for Eclipse that lead me to believe that this is an IDE worth learning, even if you're going to do most of your work on the command line. I have installed XCode based on what I saw at the Apple booth at the SC2004 - I really like the tools that Apple has developed. However, I've yet to really play with it and see what can be done. I haven't been able to find much about using XCode for Python, so I'm assuming that there isn't much in the way of support. (I take that back, I just went to http://developer.apple.com and discovered that XCode will interpret Python files and does provide syntax hilighting. Learn something new every day...) I have done most of my Python programming in Linux using the command line, IDLE, and Emacs. This isn't supported very well out of the box by OS X, as I prefer the "prettier" GUI Emacs implementations over the straight Terminal if I can get it. There are a couple of Carbon implementations out there for Emacs, and one of them includes the python Emacs module for syntax highlighting and auto-indentation. I don't remember off the top of my head which one it is. If you're interested, I can check on Monday when I get back to work and let you know. One of the Carbon implementations of Emacs plus macPython gets me pretty much where I was comfortable in Linux, so I'm happy there. The tools are available for OS X - it may take a bit of digging, but I'm coming to the conclusion that OS X is the OS I've been looking for for a while. Good luck with your searching. Abe Mathews -- http://mail.python.org/mailman/listinfo/python-list
Re: [Python-Help] Programming help
I guess I don't understand what "freq" is doing. However, you could
do something like:
num_list = []
while len(num_list) < count:
number = input("Enter a number:")
num_list.append(number)
print num_list
That may give you what you're looking for to print the list of input numbers.
Abe Mathews
On Mon, 6 Dec 2004 12:07:58 +1000, Alfred Canoy <[EMAIL PROTECTED]> wrote:
> Please help me out:(.. I've been trying to figure this out for 2 days now..
> I don't know what to use to print all the list of numbers. I hve know idea
> how should I do this. I tried a lot of trial & error for the the def, dict,
> .list( ). have no luck.
> I just need to find this out then I'm good to go for the whole thing. I have
> save the other test source code for this problem. I just need to combine it
> after I figure this out.
> Thank you all!
>
>
>
>
> Source code:
>
> # compute the Mean, Median & Mode of a list of numbers:
>
> sum = 0.0
>
> print 'This program will take several numbers then average them'
> count = input(' How many numbers would you like to sum: ')
> current_count = 0
> freq = {}
> freq [current_count] = number
>
> while current_count < count:
> current_count = current_count + 1
> number = input ('Enter a number: ')
> print "Number", current_count,":",number
> sum = sum + number
> print " [x,...,x] ?"
>
> Al
> _ _
> _ _
> Alfred Canoy
> Agana, Guam
> Pacific time
> [EMAIL PROTECTED]
>
> - Original Message -
> From: "Matthew Dixon Cowles" <[EMAIL PROTECTED]>
> To: "Alfred Canoy" <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>
> Sent: Monday, December 06, 2004 11:50 AM
> Subject: Re: [Python-Help] Programming help
>
> > Dear Alfred,
> >
> >> I'm stuck in the end of my source code. I'm trying to print all the
> >> numbers. How can I print all the list of numbers that I selected?
> >
> > What have you tried and how did the results differ from what you
> > expected?
> >
> > Regards,
> > Matt
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
--
http://mail.python.org/mailman/listinfo/python-list
Re: The python2.4 IDLE can't be lanuched.
Don't know if this would help or not, but on my Linux 2.3 IDLE, I get the following warning on startup: Personal firewall software may warn about the connection IDLE makes to its subprocess using this computer's internal loopback interface. This connection is not visible on any external interface and no data is sent to or received from the Internet. I'm not running SP 2 on any machines, so I can't test it for you, but it may be that the personal firewall being activated on SP 2 is blocking IDLE from starting up. You might try turning that off and seeing if that helps. IIRC, part of SP 2 was port disabling. I have to install SP 2 on a machine later today. If I get the chance I'll test it and see if I can make the same failure occur. Abe Mathews On Mon, 06 Dec 2004 11:28:56 -0500, Brian Beck <[EMAIL PROTECTED]> wrote: > Brian Beck wrote: > > I have the exact same problem. The IDLE window just never opens, and > > checking the process list shows that is was never even launched. So I > > can't make much use of Python 2.4 since I use IDLE as my IDE... > > I forgot to note that I am also using Windows XP SP2 and this happens on > two completely different machines of mine. > > > > -- > Brian Beck > Adventurer of the First Order > -- > http://mail.python.org/mailman/listinfo/python-list > -- http://mail.python.org/mailman/listinfo/python-list
Re: newsgroups
I've got mine delivered to a gmail account. For me, it was much easier than trying to find a NNTP host that would allow me to check remotely (many ISP's don't). Set up a filter so that everything that comes in from the list is marked "Python". Star anything that looks promising, delete the rest. I've yet to use more than 6% of the total allowed space. Abe Mathews On Sun, 12 Dec 2004 19:52:10 -0500, Francis Lavoie <[EMAIL PROTECTED]> wrote: > Egor Bolonev wrote: > > > On Sun, 12 Dec 2004 14:57:50 -0500, Francis Lavoie <[EMAIL PROTECTED]> > > wrote: > > > >> Do we need a special account or something to use the newsgroup > >> instead of the mailling list? > > > > > > why we use newsgroup instead of mailing list? > > 1. to keep my mail separated from the python discussion. > And this mailinglist/newsgroup is quite big, 150 messages a day, is > a lot of mail to go trough. > It is easier to delete all mail without deleting my own one when I > want to. Sometime there's subject I dont have answer or dont interest > me. Othertime I'm tired or I didn't check my mail for a couple of day > and it has become huge. > 2. Better and faster search. Has I said, I dont want to keep all these > mail in my mail box > 3. I don't want to be notice 2 time per minute for mail. I prefer using > it like a forum > > > > >Yes, you have to find an NNTP server that carries comp.lang.python. > It's possible your Internet service provider runs such a news server and > will let you access it as a part of your subscription (this is the case > for me). If not then you'll have to contract with a third party news > service (some of htese are available for free). > > >Alternatively, take a look at http://www.gmane.com/, a mailing > list/newsgroup interface service which I believe offers an NNTP service. > >regards > > Steve > > thank you, I was not well informed on how it does work. I though it was > like a mailinglist or jabber like, just add it in your news section and > it will connect directly on a news server. But it work now. > > > > > -- > http://mail.python.org/mailman/listinfo/python-list > -- http://mail.python.org/mailman/listinfo/python-list
Re: Python IDE
On 15 Dec 2004 12:18:15 -0800, fuzzylollipop <[EMAIL PROTECTED]> wrote: > TruStudio for Eclipse is nice for those everything must be free > socialists. -OR- - Those who are new to python, more comfortable in an IDE, and want a Python-enabled IDE that they can use without having to pay now - Those who would prefer to use one IDE for many different languages that may include Java and C/C++ - Those who have been doing the "Emacs/Vi" and command line thing for a while and would like to try an IDE without having to pay yet - Those who may have to work on multiple different platforms (say Linux, Windows, and OS X) on a day-to-day basis and would rather not have to maintain multiple different IDE skillsets for the same languages - Those who are dabbling in Python, aren't sure that they're going to stick with it, and would have a hard time justifying spending money on a piece of software that they may not use again in a month There are certainly great "for pay" IDE's out there, and Eclipse may lack huge featuresets that these commercial IDE's have. Howerver, to suggest that those who would use Eclipse are socialists kinda rankles, you know? -- http://mail.python.org/mailman/listinfo/python-list
Re: (was Re: Xah's Edu Corner: Criticism vs Constructive Criticism)
> > > > Wake up, people ! You are not the victims, you are the problem. Shut up, > > > > /please/. > > > > > > Cannot agree more! > > > > > > Wake up, people ! You are not the victims, you are the problem. Shut up, > > > /please/. > > > > Wholeheartedly agree! > > > > Wake up, people ! You are not the victims, you are the problem. Shut up, > > /please/. > > So true! > > Wake up, people ! You are not the victims, you are the problem. Shut up, > /please/. > Me too! Wake up, people ! You are not the victims, you are the problem. Shut up, /please/. -- http://mail.python.org/mailman/listinfo/python-list
