Announcing
--
The 2.7.1.1 release of wxPython is now available for download at
http://wxpython.org/download.php. This release is the first offical
release in the 2.7.x development series, and includes a lot of new
features, enhancements and fixes. Source and binaries are available
for
I am a mere hobbyist. Spent several hours trying to make a class,
because I think this is an occasion where I need one. But I can't make
it work.
This code works (only because of the global c, which I know I'm
supposed to avoid, by using a Class). I edited the rest to leave out
the irrelevant
Hi,
I just want to upgrade my python version from 2.4.3 to 2.4.4,do I need
to uninstall python 2.4.3 first ?
I'd rather not to do so, because I have installed some other python
packages for python2.4.3.
Thanks.
xiaojf
--
http://mail.python.org/mailman/listinfo/python-list
there's a page on the py2exe site about tweaks necessary for specific
modules:
http://www.py2exe.org/index.cgi/WorkingWithVariousPackagesAndModules
look for:
If you're getting File xml\sax\saxexts.pyc, line 77, in
make_parser; xml.sax._exceptions.SAXReaderNotAvailable: No
Christopher Taylor schrieb:
This basically means to me that Python2.4 is loading gloab.py from
/usr/lib64/Python2.3 insead of /usr/lib/Python2.4 (even thought I
wanted to install the related files in /usr/lib64/Python2.4)
Can someome please help!
Can you please report what sys.path is? Do
[EMAIL PROTECTED] wrote:
I just want to upgrade my python version from 2.4.3 to 2.4.4,do I need
to uninstall python 2.4.3 first ?
afaik, no.
/F
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] schrieb:
I just want to upgrade my python version from 2.4.3 to 2.4.4,do I need
to uninstall python 2.4.3 first ?
I'd rather not to do so, because I have installed some other python
packages for python2.4.3.
You don't have to uninstall. Installing on top will work just
Announcing: compiler2
-
For all you bytecode enthusiasts: 'compiler2' is an alternative to the
standard
library 'compiler' package, with several advantages.
Improved pure-python compiler
- Produces identical bytecode* to the built-in compile function for all /Lib
and
Whoah. At least I got the connection. I think. Maybe I can figure more
on my own. Any help appreciated.
Thanks
-
class Connection:
def __init__(self, aDatasource):
self.db = aDatasource
self.conn = odbc.DriverConnect(self.db)
self.conn.cursor()
def
BartlebyScrivener wrote:
I am a mere hobbyist. Spent several hours trying to make a class,
because I think this is an occasion where I need one. But I can't make
it work.
This code works (only because of the global c, which I know I'm
supposed to avoid, by using a Class). I edited the rest
BartlebyScrivener wrote:
I am a mere hobbyist. Spent several hours trying to make a class,
because I think this is an occasion where I need one. But I can't make
it work.
This code works (only because of the global c, which I know I'm
supposed to avoid, by using a Class). I edited the rest
Wow,
That's great, James.
Thanks. I shall put it together.
Appreciate it.
rd
--
http://mail.python.org/mailman/listinfo/python-list
At Friday 20/10/2006 02:38, [EMAIL PROTECTED] wrote:
it's handy for doing things like validation of parameter and return
types. Like...
@accepts(int,int)
@returns(int)
def add(a,b):
return a+b
So, it's handy for converting Python into another language :)
--
Gabriel Genellina
Softlab
Fredrik Lundh [EMAIL PROTECTED]wrote:
8---
'a man a plan a canal panama' is not a palindrome
?
not if spaces count -
able was I ere I saw elba - is one - but its a tougher test...
- Hendrik
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
I have inheirted some existing code, that i will explain in a moment,
have needed to extend and ultimately should be able to run in threads.
I've done a bunch of work with python but very little with threads and
am looking for some pointers on how to implement, and if
Brad [EMAIL PROTECTED] wrote:
Steven D'Aprano wrote:
Gah!!! That's *awful* in so many ways.
Thanks... I'm used to hearing encouragement like that. After a while you
begin to believe that everything you do will be awful, so why even
bother trying?
rant
It has been my experience that
rick wrote:
...
see that the sequence is reversed. Backwards is pure, simple and easy.
This is not so in Python and it should be.
foo[::-1] isn't pure, simple and easy?
It derives cleanly from the slice notation, it does exactly what you
want, and it even works with lists and tuples and any
On Fri, 20 Oct 2006 09:04:07 +1000, Steven D'Aprano wrote:
I agree -- the reversed() function appears to be an obvious case of purity
overriding practicality :(
str(reversed(some string))
'reversed object at 0xb7edca4c'
repr(reversed(some string))
'reversed object at 0xb7edca4c'
This
On 23. of October last year a the follwing was posted to this group:
htmlSource=urllib.urlopen(http://www.godandscience.org/images/nebula.jpg;)
# Read from the object, storing the page's contents in 's'.
s = htmlSource.read()
htmlSource.close()
myfile = open(myfile.jpg, w)
myfile.write(s)
Paul wrote:
.join(sum(map(list,zip(s,s[len(s)/2:])),[]))
perhaps?
Not quite as elegant as a string.shuffle would be, am I right?
-Jeff
This email is intended only for the individual or entity to which it is
addressed. This email may contain information that is privileged, confidential
or
Hans Olav Hygen wrote:
myfile = open(P:\Jobb\Prosjekt\Maanedsoversikt\myfile.jpg, wb)
myfile.write(s)
myfile.close
make that myfile.close()
But the images get cropped at the bottom.
files are closed when the program exits (unless it does so in an uncontrolled
way),
so I assume you were
Dear list members,I have the binary content of an image file and it's filename.I neither know the resolution nor the dpi of the image.No I need to convert this binary content into a 72 dpi jpeg image.
Furthermore I have to resize the image so neither the width nor the height is bigger than 250
The Ruby approach makes sense to me as a human being.
http://happyfuncog.blogspot.com/2006/09/confessions-of-pseudo-misanthrope.html
The Python approach is not easy for me (as a human being) to remember.
I always thought we Pythonistas are already idiots but whenever I meet
a Rubist it ( the
Hi all,
Just wondering if anyone knows how to get the text between the tags of
the following Tag object?
span class=nametextHello/span
Cheers
--
http://mail.python.org/mailman/listinfo/python-list
Brad [EMAIL PROTECTED] wrote:
Do you have children? How would your child feel if he brought you
something he had made and you then told him it was awful in *sooo* many
ways.
If you're arguing that everything a child does and says should be rewarded,
I seriously doubt that you have any.
(on
Hendrik van Rooyen wrote:
'a man a plan a canal panama' is not a palindrome
not if spaces count -
which they do if you rely on a single reverse operation (my point was
that it takes a bit more work than that to check for a palindrome).
/F
--
On Wednesday 18 October 2006 23:05, Ant wrote:
allow = re.compile(r'.*(?!\.com)\.my(|$)') # negative lookbehind
if allow.search(adr):
return True
return False
I'd point out that :
allow = re.search(r'.*(?!\.com)\.my(|$)',adr)
Will do as yours, since the call to 're'
Paul Rubin http://[EMAIL PROTECTED] wrote:
There's a language called Picolisp in which this is the standard way
to do a gui. Picolisp includes a java applet that can do some stuff
that standard html widgets can't. These days I suppose it should use
AJAX.
Yes, in fact it does.
The currently
James Stroud wrote:
alex23 wrote:
Emma wrote:
5. Please provide us with a comparison of the following music discovery
sites:
http://www.blogmusik.net
http://www.seeqpod.com/music
http://www.finetune.com
http://www.webjay.com
For each of these we like to know:
A) What you like
I'm not a coder.. I'm just a person that trys to do things with
languages he likes. Sometimes I'm successful, mostly not. I do know
that before I bother a list with a silly question I should do my best
to research for an answer myself. ala RTFM. That said my searches
haven't found me what I am
Fidel wrote:
Could someone please tell me what I need to put into a python script
to not have a window come up however briefly?
assuming Windows, and assuming that you have a standard Python install for
Windows: use pyw instead of py as the script's extension.
(Windows applications come in
hello we would like to make you discover a new and free multiplayer
game platform: GameLAN.
All game are made with pygame, we have 3 multiplayer games now (Tetris
like game, Heroic fantaisy tactic game and gomoku game). We invite you
on the 22th of October at 4pm (Paris Time) to discover this
In [EMAIL PROTECTED], placid wrote:
Hi all,
Just wondering if anyone knows how to get the text between the tags of
the following Tag object?
span class=nametextHello/span
Are you looking for a way to search for tag *and* attributes? What about
this::
In [12]: soup.find('span',
WakeBdr schrieb:
Diez,
I get what that accomplishes now, but I'm having problems in my
implementation. I was able to write a standalone class that worked
correctly. However, in my code the class that I need to exhibit this
functionality inherits from another class. This seems to cause
Hi,
I am using python2.4.1
I need to pass russian text into python and validate the same.
Can u plz guide me on how to make my existing code support the
russian text.
Is there any module that can be used for unicode support in python?
Incase of decimal numbers, how to handle comma as a decimal
sonald wrote:
I need to pass russian text into python and validate the same.
Can u plz guide me on how to make my existing code support the
russian text.
Is there any module that can be used for unicode support in python?
Python has built-in Unicode support (which you would probably have
http://www.google.com/search?q=python+unicode
(and before anyone starts screaming about how they hate RTFM replies, look
at the search result)
/F
--
http://mail.python.org/mailman/listinfo/python-list
Why the third print stement output 'comments': [(1, 2, 3)], I think
it should be [].
I am using
Python 2.4.2 (#67, Sep 28 2005, 12:41:11) [MSC v.1310 32 bit (Intel)]
on win32.
# program
class PicInfo:
def __init__(self, intro=, tags=, comments=[]):
self.picintro = intro
BartlebyScrivener wrote:
I am a mere hobbyist. Spent several hours trying to make a class,
because I think this is an occasion where I need one. But I can't make
it work.
This code works (only because of the global c, which I know I'm
supposed to avoid, by using a Class). I edited the rest
BartlebyScrivener wrote:
Whoah. At least I got the connection. I think. Maybe I can figure more
on my own. Any help appreciated.
Thanks
-
class Connection:
def __init__(self, aDatasource):
self.db = aDatasource
self.conn = odbc.DriverConnect(self.db)
HYRY [EMAIL PROTECTED] wrote:
Why the third print stement output 'comments': [(1, 2, 3)], I think
it should be [].
default arguments are calculated once. for details, see the tutorial
http://docs.python.org/tut/node6.html#SECTION00671
and the FAQ:
Bruno Desthuilliers wrote:
First, notice that you *don't* need a class here to avoid globals.
Learning to use function as *functions* (ie: taking arguments and
returning values) instead of procedure would help:
def random_quote(cursor):
c.execute (SELECT COUNT(Quote) FROM PythonQuoteQuery)
HYRY wrote:
Why the third print stement output 'comments': [(1, 2, 3)], I think
it should be [].
I am using
Python 2.4.2 (#67, Sep 28 2005, 12:41:11) [MSC v.1310 32 bit (Intel)]
on win32.
# program
class PicInfo:
def __init__(self, intro=, tags=, comments=[]):
This is a FAQ - and
Ron Adam wrote:
Leo Kislov wrote:
Ron Adam wrote:
locale.setlocale(locale.LC_ALL, '') # use current locale settings
It's not current locale settings, it's user's locale settings.
Application can actually use something else and you will overwrite
that. You can also affect
Hi,
As I am no expert web programmer I thought I'd better ask the experts if
there is a simpler or better solution to my problem than the one I am
thinking of. (using TurboGears)
The problem
---
I have a form. Ok. you can submit, validate it etc.
Now I have a link on that form to
[EMAIL PROTECTED] wrote:
Thanks, John and Neil, for your explanations.
Still I find it rather difficult to explain to a Python beginner why
this error occurs.
Suggestion: shouldn't an error raise already when I try to assign s2? A
normal string should never be allowed to contain characters
[EMAIL PROTECTED] wrote:
Suggestion: shouldn't an error raise already when I try to assign s2?
variables are not typed in Python. plain assignment will never raise an
exception.
/F
--
http://mail.python.org/mailman/listinfo/python-list
On 10/19/06, TiNo [EMAIL PROTECTED] wrote:
Now I know where the problem lies. The character in the actual file path is
u+00B4 (Acute accent) and in the Itunes library it is u+2019 (a right curly
quote). Somehow Itunes manages to make these two the same...?
As it is the only file that gave me
Hi,
I'm trying to learn Python and I'd appreciate any comments about my
small snippets of code. I read an old anecdote about performance here:
http://www.python.org/doc/essays/list2str/
First, I tried to figure out what would be the most pythonic approach by
today's standards:
def
spr wrote:
When performance matters and you have to develop a CPU-bound
application, do you think it is possible to eventually achieve nearly
the best performance by extending Python with C or C++ modules, or is it
better to take the embedding approach, that is, use a C or C++ core that
-Original Message-
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
rg] On Behalf Of Fredrik Lundh
Sent: 20 October 2006 06:43
To: python-list@python.org
Subject: Re: Tkinter--does anyone use it for sophisticated
GUI development?
Kevin Walzer wrote:
Coming from
Marc 'BlackJack' Rintsch wrote:
In [EMAIL PROTECTED], placid wrote:
Hi all,
Just wondering if anyone knows how to get the text between the tags of
the following Tag object?
span class=nametextHello/span
Are you looking for a way to search for tag *and* attributes? What about
Gregor Horvath wrote:
Hi,
As I am no expert web programmer I thought I'd better ask the experts if
there is a simpler or better solution to my problem than the one I am
thinking of. (using TurboGears)
The problem
---
I have a form. Ok. you can submit, validate it etc.
Now I
Fredrik Lundh wrote:
Bruno Desthuilliers wrote:
First, notice that you *don't* need a class here to avoid globals.
Learning to use function as *functions* (ie: taking arguments and
returning values) instead of procedure would help:
def random_quote(cursor):
c.execute (SELECT COUNT(Quote)
Folks,
Sorry for asking you such a trivial question.!!! But i want to size up
all the buttons with the same size as the largest one in the interface.. And
thats why I am asking this question..
Regards,
Asrarahmed
Hi
Asrarahmed. I think, from your
Hello.
Is there any good information about python's internals and semantic? I
mean under the hood.
For example, I want to understant what do these strings
x = 10
y = 10
x = 20
mean (memory allocation for object? ctors? etc.)
Unfortynatly, I'm too lazy to read python's source code :) (and I
Hi all
I have been trying to set up a framework with logging implemented using
the built in Python logging module. For better or worse, I have decided
to base the logger names on the module names. This means that I am
using multiple layers of name, eg logging.getLogger(a.b.c). I am also
using
[EMAIL PROTECTED] wrote:
Is there any good information about python's internals and semantic? I
mean under the hood.
For example, I want to understant what do these strings
x = 10
y = 10
x = 20
mean (memory allocation for object? ctors? etc.)
reading this might help:
Fredrik Lundh wrote:
Brad [EMAIL PROTECTED] wrote:
Do you have children? How would your child feel if he brought you
something he had made and you then told him it was awful in *sooo* many
ways.
If you're arguing that everything a child does and says should be rewarded...
I'm not
Thanks for the answer.
--
http://mail.python.org/mailman/listinfo/python-list
Fredrik Lundh wrote:
http://www.google.com/search?q=python+unicode
(and before anyone starts screaming about how they hate RTFM replies, look
at the search result)
/F
Thanks!! but i have already tried this...
and let me tell you what i am trying now...
I have added the following line
does anyone know of a good book that about development of database
applications?
Scott Ambler's Agile Database Techniques
Thanks for the hint, the summaries indicate that this one could be very
useful indeed.
Sincerely,
Wolfgang Keller
--
My email-address is correct.
Do NOT remove
Hi all: I have this list thing as a result of a db.query: (short version)
result = [{'service_id' : 1, 'value': 10},
{'service_id': 2, 'value': 5},
{'service_id': 1, 'value': 15},
{'service_id': 2, 'value': 15},
]
and so on...what i
On 2006-10-20, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Hello.
Is there any good information about python's internals and semantic? I
mean under the hood.
Not exactly 'under the hood', but very close is the Python/C API.
You can learn a great deal by reading the ExtendingEmbedding manual as
Demel, Jeff [EMAIL PROTECTED] wrote:
I've been programming professionally for over 10 years, and have never
once needed to reverse a string. Maybe it's a lack of imagination on my
part, but I can't think of a single instance this might be necessary.
I did want to reverse some strings once,
Thanks, Bruno. Very educational.
rd
Bruno Desthuilliers wrote:
Think of a class as both a blueprint for objects and a factory
creating these objects. The class lets you define the attributes and
behaviors of it's instances.
First, notice that you *don't* need a class here to avoid globals.
Thank you all!
My main problem is going away from Python and programming for weeks or
months at a time, then picking up where I left off. But Python is much
better in this regard than Perl.
I appreciate the help.
rd
-
Dennis Lee Bieber wrote:
If using a db-api compliant
Gerardo Herzig [EMAIL PROTECTED] wrote:
Hi all: I have this list thing as a result of a db.query: (short
version) result = [{'service_id' : 1, 'value': 10},
{'service_id': 2, 'value': 5},
{'service_id': 1, 'value': 15},
{'service_id': 2,
The project web is activated
http://webda.python-hosting.com/
GinTon wrote:
I have created several tables in CSV format with globalization data
(G11n). There are tables for countries, areas, languages, countries
languages, time zones, phones. And they are licensed under a Creative
Commons
result = [{'service_id' : 1, 'value': 10},
{'service_id': 2, 'value': 5},
{'service_id': 1, 'value': 15},
{'service_id': 2, 'value': 15},
]
and so on...what i need to do is some list comprehension that returns me
something like
sonald schrieb:
Fredrik Lundh wrote:
http://www.google.com/search?q=python+unicode
(and before anyone starts screaming about how they hate RTFM replies, look
at the search result)
/F
Thanks!! but i have already tried this...
Tried - might be. But you certainly didn't understand it. So I
sonald wrote:
I have added the following line in the script
# -*- coding: utf-8 -*-
that's good.
I have also modified the site.py
that's bad, because this means that your code won't work on standard
Python installations.
Now when I try to validate the data in the text file
say abc.txt
Paul Rubin wrote:
Brian Blais [EMAIL PROTECTED] writes:
I want to set up a system where I can have my family members write
comments about a number of pictures, as part of a family tree project.
...Any suggestions would be greatly appreciated!
How about a wiki?
So I thought about a wiki
Gerardo Herzig wrote:
Hi all: I have this list thing as a result of a db.query: (short version)
result = [{'service_id' : 1, 'value': 10},
{'service_id': 2, 'value': 5},
{'service_id': 1, 'value': 15},
{'service_id': 2, 'value': 15},
James Stroud wrote:
Also, look at my modest program at passerby.sf.net.
Not so sophisticated, but not completely simple either.
I did look at passerby--a nice app, and in a native Mac OS X version
also! (I'm a Mac developer.) Thanks for the pointer.
--
Kevin Walzer
Poetic Code
Brian Blais [EMAIL PROTECTED] writes:
How about a wiki?
So I thought about a wiki (again having no experience there
either...sigh). You can put images in a wiki? I had a quick look
at pytw, but haven't had the time to really dive into it to see if I
could get it going, and if it would
[EMAIL PROTECTED] wrote:
Hello,
Is there any add on python modules suitable for finite element 3D mesh
such as to create (beam, plate, etc) ?
Best Regards,
ajikoe
Google is your friend:
http://www.python.org/pycon/papers/pysparse.html
http://sourceforge.net/projects/feval/
Fredrik Lundh wrote:
on the other hand, such wrappers are usually extremely simple, and the
mapping between Python and Tk is trivial. there's simply not much to
add to the existing Tk module docs.
I think I might simply have to bite the bullet, actually use some of
these documented
OK, I think I'm close now. I just can't get past this one error. Here
is my code, followed by the output produced when I run it.
class Magic(type):
def __new__(cls, name, bases, d):
for name, function in d.items():
try:
Hi,
Anyone know about existing code supporting FTP over SSL?
I guess pycurl http://pycurl.sourceforge.net/ could be used, but that
requires knowledge of libcurl, which I haven't.
regards
--
http://mail.python.org/mailman/listinfo/python-list
I delved in the code and found that when my logger a.b.c is created,
it doesn't create Loggers for a.b or a but rather instances of a
PlaceHolder class. If I actually call logging.getLogger(a.b) and
logging.getLogger(a) then the PlaceHolders get converted to Loggers
and the hierarchy
I V wrote:
On Fri, 20 Oct 2006 09:04:07 +1000, Steven D'Aprano wrote:
I agree -- the reversed() function appears to be an obvious case of purity
overriding practicality :(
str(reversed(some string))
'reversed object at 0xb7edca4c'
repr(reversed(some string))
'reversed object at
WakeBdr schrieb:
OK, I think I'm close now. I just can't get past this one error. Here
is my code, followed by the output produced when I run it.
Stupid mistake of me - I didn't properly create a closure for the
functions to set. See the corrected version in the attachment.
Diez
Tim N. van der Leeuw wrote:
In practice, the short-term fix would be to add a __str__ method to the
'reversed' object
so what should
str(reversed(range(10)))
do ?
and perhaps to all iterators too (so that trying to build a string from an
iterator would do the obvious thing).
all
Is there some way that the user can access the docstring specified for a
property?
Please see the example below:
# propDocTest
class A(object):
def __init__(self, value):
self.value= value
def vGet(self):
return self.value
V= property (fget= vGet, doc=Get Value.)
a= A(22)
On Friday 20 October 2006 02:40, Ron Adam wrote:
I see, is this a cleanup script to remove the least wanted items?
Yes. Probably will remain in this mode for a while.
I'm not prepaired to bring out a new algorithm
Or is it a bit of both? Why the score?
As exposed on another post. There
***
Your mail has been scanned by InterScan MSS.
***
On Friday 20 October 2006 07:29, gel wrote:
Once you get a way to access the bytes to recover... the Hachoir library
can be interresting as a model to map structures on these data.
***
Your mail has been scanned by InterScan MSS.
***
On Friday 20 October 2006 14:34, James Stroud wrote:
You really don't need classes for this
I'm in that matter too. Doesn't classes make the main program neater?
Fundamentally OOP is the way to
***
Your mail has been scanned by InterScan MSS.
***
Hello,
I'm used to put up programs (small right now), but I could find the only way
to define some functions.
I'm interested to split some function into class, but I don't have know-how
for these
Colin J. Williams schrieb:
Is there some way that the user can access the docstring specified for a
property?
You need to access it using the class, not an instance of it.
class Foo(object):
@apply
def prop():
def fget(self):
return 10
def fset(self,
Kevin Walzer a écrit :
Am I better off biting the bullet and learning wxPython--a different GUI
paradigm to go with the new language I'm trying to learn? I had hoped to
reduce my learning curve, but I'm very concerned that I simply can't do
what I want to do with Tkinter. What do other Tkinter
Hi again
I have seen my error! I was mistakenly occasionally creating the logger
using
logger = logging.Logger(a.b.c)
instead of
logger = logging.getLogger(a.b.c)
Doh. I miss my private constructors to save me from such embarrasment
;^)
Cheers
Robert
--
If I have a list
Mylist=[1,2,3,4,5]
I can print it
for i in Mylist:
print i
and results is
1
2
3
4
5
But how can I print it in a reverse order so that I get
5
4
3
2
1
?
Thanks.
L
--
http://mail.python.org/mailman/listinfo/python-list
Fulvio wrote:
Looking for documents (free download) which clearly explain the way of
programming python classes and lots of examples as a bonus.
http://www.freenetpages.co.uk/hp/alan.gauld/
On the frames page, go down to Advanced Topics and Object Oriented
Programming
And from the other
Lad a écrit :
If I have a list
Mylist=[1,2,3,4,5]
I can print it
for i in Mylist:
print i
and results is
1
2
3
4
5
But how can I print it in a reverse order so that I get
5
4
3
2
1
?
Thanks.
L
for i in reversed(Mylist):
print i
--
You are the man, you are the man!! Yes, i need those dicts in order to
assign them to a nested TMPL_LOOP for the htmltmpl templating engine.
Thats why i cant use the solution provided by Max, and thanks to Jon too!!
Thanks a lot dudes, i hope someday ill turn myself into some of you guys
who
Gerardo Herzig [EMAIL PROTECTED] writes:
You are the man, you are the man!! Yes, i need those dicts in order to
assign them to a nested TMPL_LOOP for the htmltmpl templating
engine. Thats why i cant use the solution provided by Max, and thanks
to Jon too!!
I'm confused, can't you write a
Lad wrote:
If I have a list
Mylist=[1,2,3,4,5]
I can print it
for i in Mylist:
print i
and results is
1
2
3
4
5
But how can I print it in a reverse order so that I get
5
4
3
2
1
?
Thanks.
L
reverse the list in place with reverse method
l.reverse()
for i in l:
Gerardo Herzig wrote:
Thanks a lot dudes, i hope someday ill turn myself into some of you guys
who can actually answer questions ;)
if you want to become a good Python programmer, you really need to get
over that I need a oneliner idea.
/F
--
Gerardo Herzig wrote:
[...]
and so on...what i need to do is some list comprehension that returns me
something like
[...]
You don't _need_ a list comprehension, you just _want_ one :)
[...]
Ill keeping blew off my hair and drinking more cofee while searching for
this damn onliner im
1 - 100 of 224 matches
Mail list logo