Some experience using python

Just getting started with python, because just a little demand, so write a little program, a little bit of experience.

advantage:

1. os.rename () method is good, c # does not have this method

2. The well string slice operation, sometimes more convenient to take substring

3. The single block of code can be run, easy to write applets

4. [(Foo, bar) for i, j in abc] the so-called list comprehension of good writing

5.pydub This library provides detect_silence method, NAudio did this approach

Disadvantages:

1. There is no switch statement, not very convenient

2. Write gui not as easy to c #

3. No operator +, + = 1 have to be written, little trouble

4. There is no goto statement is not convenient (for example, to jump from the outermost nested loop, which is the author of Compiler Design in C Allen Holub as one example of the rational use of the goto statement), although the use of the goto statement is not many

5. spaces to indent readability as good as brackets

Guess you like

Origin www.cnblogs.com/badnumber/p/11241858.html