Re: [Tutor] longest common substring

2011-11-12 Thread lina
On Sat, Nov 12, 2011 at 5:49 AM, Andreas Perstinger
 wrote:
> First, just a little rant :-)
> It doesn't help to randomly change some lines or introduce some new concepts
> you don't understand yet and then hope to get the right result. Your chances
> are very small that this will be succesful.
> You should try to understand some basic concepts first and build on them.
> From your postings the last weeks and especially from today I have the
> impression that you still don't understand how fundamental programming
> concepts work: for-loops, differences between data types (strings, lists,
> sets, ...)
> Honestly, have you already read any programming tutorial? (You'll find a big
> list at http://wiki.python.org/moin/BeginnersGuide/NonProgrammers )? At the
> moment it looks like you are just copying some code snippets from different
> places and then you hopelessly try to modify them to suit your needs. IMHO
> the problems you want to solve are a little too big for you right now.
>
> Nevertheless, here are some comments:

Thanks, Those are very valuable comments. Since I read your post till
the following hours, my mind was haunted by what you pointed out.
The reflection went far away. I had/have a VERY BAD HABIT in learning
and doing things.
My father used to say I was the person did not know how to walk, but
started to run.
Later I realized in my life, such as I barely read a manual/usage/map,
but started messing things up.
(I did destory something I newly bought without spending 2 mins
reading the usage, I could not forget because it's expensive, haha
...).
In the past, for difficulty questions I could do pretty not bad, but
for basic concepts or step by step detailed things I failed more than
once.

But also very honestly answering, that I did try to read some books,
one is dive into python, another is learning python the hard way. and
now I have programming python by Mark Lutz, and another python book on
bedside.
The mainly problems was that I felt nothing when I just read for
reading. forget so easily what I read.
( Now I am a little worried, the bad habit I have had will affect me
go far away or build something serious. Sigh ... )
In the past hours, I tried to read the basic concepts, but get lost
(not lost, just mind becomes empty and inactive) in minutes.

Thanks again for your pointing out. I will remind myself in future.
>
>> Based on former advice, I made a correction/modification on the belowba
>> code.
>>
>> 1] the set and subgroup does not work, here I wish to put all the
>> subgroup in a big set, the set like
>
> That's a good idea, but you don't use the set correctly.
>
>> subgroups=[]
>> subgroup=[]
>> def LongestCommonSubstring(S1, S2):
>
> I think it's better to move "subgroups" and "subgroup" into the function.
> (I've noticed that in most of your scripts you are using a lot of global
> variables. IMHO that's not the best programming style. Do you know what
> "global/local variables", "namespace", "scope" mean?)
>
> You are defining "subgroups" as an empty list, but later you want to use it
> as a set. Thus, you should define it as an empty set:
>
> subgroups = set()
>
> You are also defining "subgroup" as an empty list, but later you assign a
> slice of "S1" to it. Since "S1" is a string, the slice is also a string.
> Therefore:
>
> subgroup = ""
>
>>      M = [[0]*(1+len(S2)) for i in xrange(1+len(S1))]
>
> Peter told you already why "xrange" doesn't work in Python 3. But instead of
> using an alias like
>
> xrange = range
>
> IMHO it's better to change it in the code directly.
>
>>      longest, x_longest = 0, 0
>>      for x in xrange(1,1+len(S1)):
>>          for y in xrange(1,1+len(S2)):
>>              if S1[x-1] == S2[y-1]:
>>                  M[x][y] = M[x-1][y-1]+1
>>                  if M[x][y]>  longest:
>>                      longest = M[x][y]
>>                      x_longest = x
>>                  if longest>= 3:
>>                      subgroup=S1[x_longest-longest:x_longest]
>>                      subgroups=set([subgroup])
>
> Here you overwrite in the first iteration your original empty list
> "subgroups" with the set of the list which contains the string "subgroup" as
> its only element. Do you really understand this line?
> And in all the following iterations you are overwriting this one-element set
> with another one-element set (the next "subgroup").
> If you want to add an element to an existing set instead of replacing it,
> you have to use the "add()"-method for adding an element to a set:
>
> subgroups.add(subgroup)
>
> This will add the string "subgroup" as a new element to the set "subgroups".
>
>>                      print(subgroups)
>>              else:
>>                      M[x][y] = 0
>>
>>      return S1[x_longest-longest:x_longest]
>
> Here you probably want to return the set "subgroups":
>
> return subgroups
I will return to this parts later.

Based on your advice, I updated the code to below one (which is partially work);

#!/usr/bin/python3

impo

Re: [Tutor] longest common substring

2011-11-12 Thread lina


Sorry I finished last email in two different time,

while:
> INFILEEXT=".doc"
>
>
> def CommonSublist(L1, L2):
>    sublist=[]
>    sublists=[]
>    result=[]
>    M = [[0]*(1+len(L2)) for i in range(1+len(L1))]
>    longest, x_longest = 0, 0
>    for x in range(1,1+len(L1)):
>        for y in range(1,1+len(L2)):
>            if L1[x-1] == L2[y-1]:
>                M[x][y] = M[x-1][y-1]+1
>                if M[x][y] > longest:
>                    longest = M[x][y]
>                    x_longest = x
>                if longest >= 2:
>                    sublist=L1[x_longest-longest:x_longest]
>                    if sublist not in sublists:
>                         sublists.append(sublist)
>
>
>            else:
>                    M[x][y] = 0
>
>    return sublists
>
>
>
> if __name__=="__main__":
>
>
>    for i in range(1,11):
>        for j in range(1,11):
>            if i != j:
>                fileone="atom-pair_"+str(i)+".txt"
>                filetwo="atom-pair_"+str(j)+".txt"

correction: here not ".txt", it's ".doc"
>                a=open(fileone,"r").readline().strip().split(' ')
>                b=open(filetwo,"r").readline().strip().split(' ')
>                print(fileone,filetwo)
>                print(CommonSublist(a,b))
>
> The output results:
>
the output is:

atom-pair_10.doc atom-pair_8.doc
[['75', '64'], ['13', '64', '75'], ['64', '62', '75', '16']]
atom-pair_10.doc atom-pair_9.doc
[['65', '46'], ['13', '75', '64']]

seems a bit better than before.

> atom-pair_10.txt atom-pair_8.txt
> [["'75',", "'64',"], ["'13',", "'64',", "'75',"], ["'64',", "'62',",
> "'75',", "'16',"]]
> atom-pair_10.txt atom-pair_9.txt
> [["'65',", "'46',"], ["'13',", "'75',", "'64',"]]
>

> the $ python3 CommonSublists.py
> atom-pair_1.txt atom-pair_2.txt
> Traceback (most recent call last):
>  File "CommonSublists.py", line 47, in 
>    print(CommonSublist(a,b))
>  File "CommonSublists.py", line 24, in CommonSublist
>    result=result.append(sublist)
> AttributeError: 'NoneType' object has no attribute 'append'
>
> in local domain I set the result=[]
> I don't know why it complains its NoneType, since the "result" is
> nearly the same as "sublists".
>

Thanks with best regards,
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] (no subject)

2011-11-12 Thread Alan Gauld

On 11/11/11 22:17, Andreas Perstinger wrote:


I don't know about windows but if you want to run the script from the
command line you have to add:

if __name__ == "__main__":
main()


No, you only need to do that if you plan on using the file as a module 
at some point. If you don't need a module then the OPs style will work 
just fine on any OS.


But since having module facilities is so easy it is good practice to 
always use the if main clause...


--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/

___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Hello again. Still the same problem, different question.

2011-11-12 Thread Robert Sjoblom
On 12 November 2011 07:27,   wrote:
> Send Tutor mailing list submissions to
>        tutor@python.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://mail.python.org/mailman/listinfo/tutor
> or, via email, send a message with subject or body 'help' to
>        tutor-requ...@python.org
>
> You can reach the person managing the list at
Please have a useful subject line next time, the current subject
doesn't tell us anything about your problem.

> Someone there told me they would've given up by now but I am not giving up
> on this one or anything else. Just to give you a heads up, you will be
> getting questions about this until this program works.

You can't force me to answer questions! Additionally; I, for one, will
put you on ignore if you spam this list with questions that are about
the same subject and are unsolvable because the standard version
doesn't work. So just to give you a heads up: don't overextend your
welcome.

-- 
best regards,
Robert S.
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


[Tutor] Time subtractrion

2011-11-12 Thread Cameron Macleod
Hi,

I've been trying to code a timer that tells you how long you've been on the
net and I can't figure out how to produce a figure in hours, minutes and
seconds that is constantly being updated. If anyone could point out a
module with functions like this or built in functions, I'd be very grateful.

Cameron
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] (no subject)

2011-11-12 Thread Andreas Perstinger

On 2011-11-12 10:33, Alan Gauld wrote:

On 11/11/11 22:17, Andreas Perstinger wrote:


 I don't know about windows but if you want to run the script from the
 command line you have to add:

 if __name__ == "__main__":
 main()


No, you only need to do that if you plan on using the file as a module
at some point. If you don't need a module then the OPs style will work
just fine on any OS.


Of course you're right. Sorry for the misinformation. It was probably 
too late in the evening when I wrote this yesterday :-(.


Bye, Andreas
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] longest common substring

2011-11-12 Thread Dave Angel

On 11/12/2011 03:54 AM, lina wrote:


The one I tried :
 if longest>= 2:
 sublist=L1[x_longest-longest:x_longest]
 result=result.append(sublist)
 if sublist not in sublists:
  sublists.append(sublist)

the $ python3 CommonSublists.py
atom-pair_1.txt atom-pair_2.txt
Traceback (most recent call last):
   File "CommonSublists.py", line 47, in
 print(CommonSublist(a,b))
   File "CommonSublists.py", line 24, in CommonSublist
 result=result.append(sublist)
AttributeError: 'NoneType' object has no attribute 'append'

in local domain I set the result=[]
I don't know why it complains its NoneType, since the "result" is
nearly the same as "sublists".


Assuming this snippet is part of a loop, I see the problem:

result  = result.append(sublist)

list.append() returns none.  It modifies the list object in place, but 
it doesn't return anything.  So that statement modifies the result 
object, appending the sublist to it, then it sets it to None.  The 
second time around you see that error.


In general, most methods in the standard library either modify the 
object they're working on, OR they return something.   The append method 
is in the first category.



--

DaveA

___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Time subtractrion

2011-11-12 Thread Wayne Werner
On Sat, Nov 12, 2011 at 6:07 AM, Cameron Macleod wrote:

> Hi,
>
> I've been trying to code a timer that tells you how long you've been on
> the net and I can't figure out how to produce a figure in hours, minutes
> and seconds that is constantly being updated. If anyone could point out a
> module with functions like this or built in functions, I'd be very grateful.


Have you looked at the time module?

http://docs.python.org/library/time.html

-Wayne
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] longest common substring

2011-11-12 Thread lina
On Sat, Nov 12, 2011 at 9:22 PM, Dave Angel  wrote:
> On 11/12/2011 03:54 AM, lina wrote:
>>
>> 
>> The one I tried :
>>                 if longest>= 2:
>>                     sublist=L1[x_longest-longest:x_longest]
>>                     result=result.append(sublist)
>>                     if sublist not in sublists:
>>                          sublists.append(sublist)
>>
>> the $ python3 CommonSublists.py
>> atom-pair_1.txt atom-pair_2.txt
>> Traceback (most recent call last):
>>   File "CommonSublists.py", line 47, in
>>     print(CommonSublist(a,b))
>>   File "CommonSublists.py", line 24, in CommonSublist
>>     result=result.append(sublist)
>> AttributeError: 'NoneType' object has no attribute 'append'
>>
>> in local domain I set the result=[]
>> I don't know why it complains its NoneType, since the "result" is
>> nearly the same as "sublists".
>>
> Assuming this snippet is part of a loop, I see the problem:
>
> result  = result.append(sublist)
>
> list.append() returns none.  It modifies the list object in place, but it
> doesn't return anything.  So that statement modifies the result object,
> appending the sublist to it, then it sets it to None.  The second time
> around you see that error.

I am sorry.  haha ... still lack of understanding above sentence.

>>> a
['3', '5', '7', '8', '9']
>>> d.append(a)
>>> d
[['3', '5', '7', '8', '9']]
>>> type(a)


Sorry and thanks, best regards,

lina

>
> In general, most methods in the standard library either modify the object
> they're working on, OR they return something.   The append method is in the
> first category.
>
>
> --
>
> DaveA
>
>
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] longest common substring

2011-11-12 Thread Dave Angel

On 11/12/2011 09:48 AM, lina wrote:

On Sat, Nov 12, 2011 at 9:22 PM, Dave Angel  wrote:

On 11/12/2011 03:54 AM, lina wrote:



The one I tried :
 if longest>= 2:
 sublist=L1[x_longest-longest:x_longest]
 result=result.append(sublist)
 if sublist not in sublists:
  sublists.append(sublist)

the $ python3 CommonSublists.py
atom-pair_1.txt atom-pair_2.txt
Traceback (most recent call last):
   File "CommonSublists.py", line 47, in
 print(CommonSublist(a,b))
   File "CommonSublists.py", line 24, in CommonSublist
 result=result.append(sublist)
AttributeError: 'NoneType' object has no attribute 'append'

in local domain I set the result=[]
I don't know why it complains its NoneType, since the "result" is
nearly the same as "sublists".


Assuming this snippet is part of a loop, I see the problem:

result  = result.append(sublist)

list.append() returns none.  It modifies the list object in place, but it
doesn't return anything.  So that statement modifies the result object,
appending the sublist to it, then it sets it to None.  The second time
around you see that error.


I am sorry.  haha ... still lack of understanding above sentence.


a

['3', '5', '7', '8', '9']

d.append(a)
d

[['3', '5', '7', '8', '9']]

type(a)



Sorry and thanks, best regards,

lina



In general, most methods in the standard library either modify the object
they're working on, OR they return something.   The append method is in the
first category.




To keep it simple, I'm using three separate variables.  d and a are as 
you tried to show above.  Now what happens when I append?


Python 2.7.1+ (r271:86832, Apr 11 2011, 18:13:53)
[GCC 4.5.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> d = []
>>> a = [3, 5, 7]
>>> xxx = d.append(a)
>>> print(repr(xxx))
None
>>> print d
[[3, 5, 7]]

Notice that d does change as we expected.  But xxx, the return value, is 
None. The append() method doesn't return any useful value, so don't 
assign it to anything.


The statement in your code that's wrong is
result = result.append(sublist)

The final value that goes into result is None, no matter what the 
earlier values of result and sublist were.


--

DaveA
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] longest common substring

2011-11-12 Thread lina
On Sat, Nov 12, 2011 at 10:57 PM, Dave Angel  wrote:
> On 11/12/2011 09:48 AM, lina wrote:
>>
>> On Sat, Nov 12, 2011 at 9:22 PM, Dave Angel  wrote:
>>>
>>> On 11/12/2011 03:54 AM, lina wrote:

 
 The one I tried :
                 if longest>= 2:
                     sublist=L1[x_longest-longest:x_longest]
                     result=result.append(sublist)
                     if sublist not in sublists:
                          sublists.append(sublist)

 the $ python3 CommonSublists.py
 atom-pair_1.txt atom-pair_2.txt
 Traceback (most recent call last):
   File "CommonSublists.py", line 47, in
     print(CommonSublist(a,b))
   File "CommonSublists.py", line 24, in CommonSublist
     result=result.append(sublist)
 AttributeError: 'NoneType' object has no attribute 'append'

 in local domain I set the result=[]
 I don't know why it complains its NoneType, since the "result" is
 nearly the same as "sublists".

>>> Assuming this snippet is part of a loop, I see the problem:
>>>
>>> result  = result.append(sublist)
>>>
>>> list.append() returns none.  It modifies the list object in place, but it
>>> doesn't return anything.  So that statement modifies the result object,
>>> appending the sublist to it, then it sets it to None.  The second time
>>> around you see that error.
>>
>> I am sorry.  haha ... still lack of understanding above sentence.
>>
> a
>>
>> ['3', '5', '7', '8', '9']
>
> d.append(a)
> d
>>
>> [['3', '5', '7', '8', '9']]
>
> type(a)
>>
>> 
>>
>> Sorry and thanks, best regards,
>>
>> lina
>>
>>>
>>> In general, most methods in the standard library either modify the object
>>> they're working on, OR they return something.   The append method is in
>>> the
>>> first category.
>>>
>>>
>
> To keep it simple, I'm using three separate variables.  d and a are as you
> tried to show above.  Now what happens when I append?
>
> Python 2.7.1+ (r271:86832, Apr 11 2011, 18:13:53)
> [GCC 4.5.2] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
 d = []
 a = [3, 5, 7]
 xxx = d.append(a)
 print(repr(xxx))
> None
 print d
> [[3, 5, 7]]
>
> Notice that d does change as we expected.  But xxx, the return value, is
> None. The append() method doesn't return any useful value, so don't assign
> it to anything.

Thanks, ^_^, now better.

I checked, the sublist (list) here can't be as a key of the results (dict).

actually I also wish to get the occurence of those sublist in the
script, except using external one in command line as uniq -c.

^_^ Have a nice weekend,

>
> The statement in your code that's wrong is
>    result = result.append(sublist)
>
> The final value that goes into result is None, no matter what the earlier
> values of result and sublist were.
>
> --
>
> DaveA
>
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] longest common substring

2011-11-12 Thread Andreas Perstinger

On 2011-11-12 16:24, lina wrote:

Thanks, ^_^, now better.


No, I'm afraid you are still not understanding.


I checked, the sublist (list) here can't be as a key of the results (dict).


"result" isn't a dictionary. It started as an empty list and later 
becomes a null object ("NoneType").


You must not forget that you are inside a for-loop. Simplified your 
situation is like this:


>>> result = []
>>> for i in range(1,10):
... print("Iteration {0}, result = {1}".format(i, result))
... result = result.append(i)
...
Iteration 1, result = []
Iteration 2, result = None
Traceback (most recent call last):
  File "", line 3, in 
AttributeError: 'NoneType' object has no attribute 'append'

As you see the error happens in the *second* iteration, because result 
is no list any more.
Dave gave you already the explanation: functions and method always 
return a value in Python. If the don't have a return statement they 
return "None".


Another simple example:

>>> a = print("Test")
Test

"print" is a function which prints out the text you passed to it and you 
usually aren't interested in its return value. But every function/method 
in Python returns something. You save this value in "a"


>>> print(a)
None

As you see the return value of "print" is "None".

>>> a.append(x)
Traceback (most recent call last):
  File "", line 1, in 
AttributeError: 'NoneType' object has no attribute 'append'

Same error as above, because "NoneType" objects (null objects) don't 
have a method "append".


I also think you mix two different ways to add an element to a list:

result.append(x)

is equivalent to

result = result + [x] (that's what you will use in other languages)

HTH, Andreas
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


[Tutor] [off-topic] Any thread for linux troubleshooting

2011-11-12 Thread Bikash Sahoo
Hi All :

Sorry guys , i know this is not the right thread. Just wanted to bump off a
question . I am new to python and have just installed linux(new to linux as
well :) ) on my system. It has both the Windows 7 and Ubuntu 11.0 now.

Can you please refer some threads for linux troubleshooting queries ??

Thanks in advance

Bikash

P.S :- Posting the query , just in case.

I am getting the following as the initial command line in the terminal when
i open it after installation . Can i change it ? is there any error in the
installation ?

"dinesh@dinesh-Invalid-entry-length-0-DMI-table-is-broken-Stop:~$ "

i want to make it just dinesh .
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] longest common substring

2011-11-12 Thread Joel Goldstick
On Sat, Nov 12, 2011 at 11:40 AM, Andreas Perstinger <
andreas.perstin...@gmx.net> wrote:

> On 2011-11-12 16:24, lina wrote:
>
>> Thanks, ^_^, now better.
>>
>
> No, I'm afraid you are still not understanding.
>
>
>  I checked, the sublist (list) here can't be as a key of the results
>> (dict).
>>
>
> "result" isn't a dictionary. It started as an empty list and later becomes
> a null object ("NoneType").
>
> You must not forget that you are inside a for-loop. Simplified your
> situation is like this:
>
> >>> result = []
> >>> for i in range(1,10):
> ... print("Iteration {0}, result = {1}".format(i, result))
> ... result = result.append(i)
> ...
> Iteration 1, result = []
> Iteration 2, result = None
>
> Traceback (most recent call last):
>  File "", line 3, in 
>
> AttributeError: 'NoneType' object has no attribute 'append'
>
> As you see the error happens in the *second* iteration, because result is
> no list any more.
> Dave gave you already the explanation: functions and method always return
> a value in Python. If the don't have a return statement they return "None".
>
> Another simple example:
>
> >>> a = print("Test")
> Test
>
> "print" is a function which prints out the text you passed to it and you
> usually aren't interested in its return value. But every function/method in
> Python returns something. You save this value in "a"
>
> >>> print(a)
> None
>
> As you see the return value of "print" is "None".
>
> >>> a.append(x)
>
> Traceback (most recent call last):
>  File "", line 1, in 
>
> AttributeError: 'NoneType' object has no attribute 'append'
>
> Same error as above, because "NoneType" objects (null objects) don't have
> a method "append".
>
> I also think you mix two different ways to add an element to a list:
>
> result.append(x)
>
> is equivalent to
>
> result = result + [x] (that's what you will use in other languages)
>
> HTH, Andreas
>
> __**_
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> http://mail.python.org/**mailman/listinfo/tutor
>

This is a fascinating thread in the same way that people can't help slowing
down and looking at a car crash on the side of the road is fascinating.

The original poster it seems is new to programming and has offered that he
likes to run before he learns to walk.  That doesn't seem like a good
proclamation to make when you are asking people to help you.  Anyway, this
particular piece of code is pretty tricky stuff.  It involves understanding
list comprehensions, multidimensional lists, and slices.  All things that
take more than a passing interest in to grasp.

Furthermore, the algorithm itself is pretty tricky.  If you follow the link
to the wikipedia article:
http://en.wikipedia.org/wiki/Longest_common_substring you learn that
understanding the algorithm requires understanding of trees (Generalized
suffix trees at that!).

I copied the code from the original article and played around with it for
an hour or so to understand it.  I didn't get the answers that I expected
either.

If you are learning coding in general and python in particular this
exercise seems unproductive.  Work through basic concepts.  If you don't
like one set of tutorials, find a different one.  if you don't like to
read, check out google videos for learning python, or youtube for that
matter.  But taking on a concise algorithm that solves a problem that would
challenge a 3rd year CS student doesn't seem like a good idea



-- 
Joel Goldstick
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Suggest Book

2011-11-12 Thread amt
Hi Pankaj!


Have a look at :

http://wiki.python.org/moin/BeginnersGuide
http://norvig.com/21-days.html


I'm currently learning from this book:
http://learnpythonthehardway.org/book/
Have a look. It's a good book for starting out.


Just pick one that you like and start learning. I wish you good luck!


Regards, amt.





On Fri, Nov 11, 2011 at 4:29 PM, Pankaj Jakhar wrote:

> Hello
>
> Please suggest me the best book for Python from which I can learn basics
> to advanced Python.
>
> Thank you.
> *
> PankaJ **Jakhar**
> *
>
> ___
> Tutor maillist  -  Tutor@python.org
> To unsubscribe or change subscription options:
> http://mail.python.org/mailman/listinfo/tutor
>
>
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] [off-topic] Any thread for linux troubleshooting

2011-11-12 Thread Alan Gauld

On 12/11/11 17:54, Bikash Sahoo wrote:


Can you please refer some threads for linux troubleshooting queries ??


Not so much a thread but the Ubuntu web forum is a good starting place 
and there are tons of Linux news groups. Try a search on Google groups 
as your starting point.


Also the Linux Documentation Project  www.ldp.org has loads of how-to docs.

I've been using Linux on and off since 1993 but only made the total 
switch to it this July. So far I'm loving it except for the lack of a 
decent Video editor and Visio clone. Fortunately Serif Movieplus and 
SmartDraw 6 work under Wine so I'm a happy bunny :-)



--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/

___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] [off-topic] Any thread for linux troubleshooting

2011-11-12 Thread Ken G.

On 12/11/11 17:54, Bikash Sahoo wrote:


Can you please refer some threads for linux troubleshooting queries ??


Not so much a thread but the Ubuntu web forum is a good starting place and thereare tons of Linux news groups. Try a search on Google groups as your 

starting point.


Also the Linux Documentation Project  www.ldp.org has loads of how-to docs.

I've been using Linux on and off since 1993 but only made the total switch to 
it this July. So far I'm loving it except for the lack of a decent Video editor 
and Visio clone. Fortunately Serif Movieplus and SmartDraw 6 work under Wine so 
I'm a happy bunny


--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/


I checked the above website and I was linked to a foreign political 
blog.  The correct link is:  tldp.org/  for The Linux Documentation Project.


Ken
___
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor