7;)#chasis =
child.before.decode('utf-8')child.expect('krishna@krishna-desktop:~/python_excercises$',timeout
= 50)child.sendline('ls -l')chasis = child.before.decode('utf-8')print(chasis)
Error :
raise TIME
hi,
i need an help in the following program
i just started to learn.
if speed >= 80:
print 'License and registration please'
if mood == 'terrible' or speed >= 100:
print 'You have the right to remain silent.'
elif mood == 'bad' or speed >= 90:
print "I'm going to have to write you a ticket."
w
hi everybody,
i wrote this to solve the problem of exact duplicate entries in my
citeulike library, that i wanted to remove. so i exported my entries in
ris format, and then parsed the entries to find exact duplicates based on
matching fields. the exact duplicates came about because i uplo
Hi,everyone.
My name is Sai krishna, and I'm new to Python as well as Programming.
I wanted to print out all the combinations of a given word.
I am doing it this way:
n='cat'
def arrange(n):
if len(n)==1: #length of word is 1
print n
elif len(n)==2: # length of word is 2
>>> 1 or 2 and 3
1
Why does the above expression return 1? As per my understanding of
boolean operations, this is what should have happaned:
1 or 2 => 1 and then
1 and 3 => 3
The library reference also suggests that 'or' has higher priority than 'and'.
http://docs.python.org/lib/boolean.html
Th
On 25/09/05, Andrei <[EMAIL PROTECTED]> wrote:
> > Think the mail system screwed up the formatting! But am fairly sure
> > that I have indented it correctly in the console. Try and Except are
> > in the column. Any other hints?
>
> Yes :). Compare:
>
> >>> try:
> ... os.system('cls')
> ... excep
On 25/09/05, ZIYAD A. M. AL-BATLY <[EMAIL PROTECTED]> wrote:
> On Sun, 2005-09-25 at 18:55 +0530, Krishna wrote:
> > When I try to run the following piece of code, I get a SyntaxError,
> > can someone help me out on this?
> >
> > try:
> > ... os.system(&quo
When I try to run the following piece of code, I get a SyntaxError,
can someone help me out on this?
try:
... os.system("cls")
... except:
... print "Foo"
... print "Bar"
Traceback ( File "", line 5
print "Bar"
^
SyntaxError: invalid syntax
What am I missing?
Thanks in advan