Module on Getting the Date Time

2005-05-10 Thread Sara Khalatbari
Is there a Modules in Python that returns the time 
date of today when ran?










__ 
Do you Yahoo!? 
Yahoo! Mail - You care about security. So do we. 
http://promotions.yahoo.com/new_mail
-- 
http://mail.python.org/mailman/listinfo/python-list


A Module on Time Date

2005-05-10 Thread Sara Khalatbari
Is there a Module in Python that gives you the time 
date of today???




__ 
Do you Yahoo!? 
Make Yahoo! your home page 
http://www.yahoo.com/r/hs
-- 
http://mail.python.org/mailman/listinfo/python-list


The first programming riddle on the net. Python-challenge

2005-05-10 Thread Sara Khalatbari
Hey guys!
Thanks for helping me find timedate.

Have you seen this?
This is the first programming riddle on the net with
20 levels! 

http://www.pythonchallenge.com/

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-- 
http://mail.python.org/mailman/listinfo/python-list


Shell Commands in Python Code

2005-05-07 Thread Sara Khalatbari
There are a lot of commands that I need to use in my
code  I don't know how to do it

Is there a way to use shell commands in Python code?



__ 
Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses. 
http://promotions.yahoo.com/new_mail
-- 
http://mail.python.org/mailman/listinfo/python-list


path(file)

2005-05-07 Thread Sara Khalatbari
Suppose I have a list of files  I wanna know  their
path.
is there a command that helps me do so in python?



Yahoo! Mail
Stay connected, organized, and protected. Take the tour:
http://tour.mail.yahoo.com/mailtour.html

-- 
http://mail.python.org/mailman/listinfo/python-list


What's this error then?

2005-05-02 Thread Sara Khalatbari
You remember me asking about running a program in my
code...I got a problem here

I copied the msgfmt here :

[EMAIL PROTECTED] HEADER]$ ls
allsamples  
Backup   
file-roller.HEAD.fa.po  
msgfmt.py
header.py  


 my code is:
#! /usr/bin/env python

import os
from os import execl

os.execl ('/home/sara/PYTHON/HEADER/msgfmt.py',
'file-roller.HEAD.fa.po')


But when I run it, this Error raises:
[EMAIL PROTECTED] HEADER]$ python run.py
/usr/bin/env: python2.2: No such file or directory

Do you have any solutions?

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-- 
http://mail.python.org/mailman/listinfo/python-list


How to run a program?

2005-04-30 Thread Sara Khalatbari
I'm writing a code that checks the header of .po file
for syntax errors. I want this program to run
msgfmt.py on the .po file first  then the rest.

How can you write a code that runs another program in
itself?

:),
Sara

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-- 
http://mail.python.org/mailman/listinfo/python-list


date to digit

2005-04-30 Thread Sara Khalatbari
Is there a program in python that inputs a date  a
time, for example:  “2005-04-17 04:20+”. And
returns a digit, for example: “3501” instead? 

and if there is such program or built-in function, how
can I run it inside a code?

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-- 
http://mail.python.org/mailman/listinfo/python-list


Codig style: or

2005-04-13 Thread Sara Khalatbari
Hi!

Suppose you're writing a module  writing the
definition of each function in that module in  or
.
for example:
a) This function does this  that
or:
b)  This function does blah blah blah

What are the differences between  and  ? 
I'm using gedit  I wanna know a bit about coding
style.

To be very honest: I have a very strict boss who looks
for bugs in my codes  he insists to know exactly
which 'CODING STYLE AUTHORITATIVE SOURCE' I've based
my coding style on when using  or .

Can anybody out there give me some hint?
Can anybody tell me where to find a document on python
coding style.

tnx,
Sara



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/
-- 
http://mail.python.org/mailman/listinfo/python-list


will it cause any problems to open a read-only file not close it?

2005-03-14 Thread Sara Khalatbari
Dear friends
In a code, I'm opening a file to read. Like :
lines = open(filename).readlines()
 I'm never closing it.
I'm not writing in that file, I just read it.

Will it cause any problems if you open a file to read
 never close it?




__ 
Do you Yahoo!? 
Make Yahoo! your home page 
http://www.yahoo.com/r/hs
-- 
http://mail.python.org/mailman/listinfo/python-list