Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Python Intro For Managers


Published on

Published in: Technology
  • Easy and hassle free way to make money online! I have just registered with this site and straight away I was making money! It doesn't get any better than this. Thank you for taking out all the hassle and making money answering surveys as easy as possible even for non-techie guys like me! ■■■
    Are you sure you want to  Yes  No
    Your message goes here
  • Follow the link, new dating source: ♥♥♥ ♥♥♥
    Are you sure you want to  Yes  No
    Your message goes here
  • Dating for everyone is here: ♥♥♥ ♥♥♥
    Are you sure you want to  Yes  No
    Your message goes here
  • If you want a girl to "chase" you, then you have to use the right "bait". We discovered 4 specific things that FORCE a girl to chase after you and try to win YOU over. copy and visiting... ♣♣♣
    Are you sure you want to  Yes  No
    Your message goes here
  • How to start a wildly profitable 7 figure marketing business and get your first commission check tonight, click here ■■■
    Are you sure you want to  Yes  No
    Your message goes here

Python Intro For Managers

  1. 1. Python: a Powerful, Easy-to-Use, Open-Source Scripting Language Stephen Ferg Bureau of Labor Statistics
  2. 2. What we're going to talk about...
  3. 3. <ul><li>Open-source applications -- or at least some of them -- are good. </li></ul><ul><li>Scripting languages are good. </li></ul><ul><li>Python is the best scripting language. </li></ul>Executive Summary Time, money, and innovative energy... can be saved. Productivity, speed, and quality ... can be improved.
  4. 4. Topics <ul><li>Scripting languages </li></ul><ul><li>Python </li></ul><ul><li>Issues surrounding use of Python </li></ul><ul><ul><li>Open-Source Software </li></ul></ul><ul><li>What the experts think </li></ul><ul><li>Where we might find Python useful </li></ul>
  5. 5. What is a &quot;scripting&quot; language? <ul><li>Interpreted </li></ul><ul><ul><li>requires a run-time interpreter or virtual machine </li></ul></ul><ul><li>Untyped or dynamically typed </li></ul><ul><ul><li>No data declarations </li></ul></ul><ul><li>No compilation step </li></ul>
  6. 6. In the beginning... <ul><li>System programming languages </li></ul><ul><ul><li>Assembler, C </li></ul></ul><ul><ul><li>Fortran, Cobol, Algol </li></ul></ul><ul><ul><li>PL/1, Pascal, Basic, C++, Java </li></ul></ul><ul><li>Command languages </li></ul><ul><ul><li>JCL </li></ul></ul><ul><ul><li>TSO CLists, CMS &quot;execs&quot; </li></ul></ul><ul><ul><li>Batch files </li></ul></ul>
  7. 7. &quot;Little Languages&quot; appear... <ul><li>awk </li></ul><ul><li>sed </li></ul><ul><li>grep </li></ul>
  8. 8. Scripting languages evolve <ul><li>UNIX shell scripting languages </li></ul><ul><li>Rexx </li></ul><ul><li>Tcl, TK </li></ul><ul><li>Perl </li></ul><ul><li>Python </li></ul><ul><li>PHP </li></ul><ul><li>Ruby </li></ul><ul><li>SAS </li></ul>Many have higher-level object-oriented features that make them powerful application development languages in their own right.
  9. 9. The defining characteristic of scripting languages... <ul><li>Vastly increased productivity! </li></ul>
  10. 10. <ul><li>&quot;Scripting: Higher Level Programmingfor the 21st Century&quot; by John K. Ousterhout </li></ul><ul><li>IEEE Computer magazine, March 1998 -- </li></ul><ul><li>Assembly Language </li></ul><ul><ul><li>One machine instruction per line </li></ul></ul><ul><li>System programming languages </li></ul><ul><ul><li>3-7 machine instructions per line </li></ul></ul><ul><li>Scripting languages </li></ul><ul><ul><li>Hundreds to thousands of instructions per line </li></ul></ul>Programmers can write roughly the same number of lines of code per year regardless of language. Productivity = the number of machine instructions that a programmer can produce per year.
  11. 11. None Strong Degree of Typing Assembler System Languages Scripting Languages VB Python, Perl, Ruby, TCL C C++ Java Instructions/Statement 1000 100 10 1 Language Levels and Productivity From &quot;Scripting: Higher Level Programming for the 21st Century&quot; by John K. Ousterhout. This version prepared by Dana Moore and updated by Stephen Ferg       
  12. 12. This leads to... increasing use of scripting languages.
  13. 13. John Ousterhout <ul><li>Scripting: Higher Level Programmingfor the 21st Century - IEEE Computer 1998 </li></ul>Scripting languages represent a different set of tradeoffs than system programming languages. They give up execution speed and strong typing but provide significantly higher programmer productivity and software reuse. This tradeoff makes increasing sense as computers become faster and cheaper compared to programmers. For the last fifteen years a fundamental change has been occurring in the way people write computer programs. ...from system programming languages to scripting languages. This article explains why scripting languages will handle many of the programming tasks of the next century better than system programming languages.
  14. 14. Robert C. Martin <ul><li>I think there is a trend in language that will become more and more evident as the decade progresses. I think we are seeing an end to the emphasis on statically typed languages like C++, Java, Eiffel, Pascal, and Ada. </li></ul><ul><li>I expect to see an ever increasing use of dynamically typed languages, such as Python, Ruby, and even Smalltalk. These languages, and languages of their kind, will be mainstream industrial languages in the coming years. </li></ul>
  15. 15. Tim O'Reilly  <ul><li>People are so stuck in the personal computer paradigm that they don't recognize that the nature of applications has undergone a profound change in the last decade, with most of the new killer apps running on what has been called the LAMP platform (Linux-Apache-MySQL-PHP | Perl | Python). People understand the importance of Linux, Apache and MySQL... but they still struggle with understanding the &quot;P&quot; in LAMP. </li></ul><ul><li>The reason why dynamic languages like Perl, Python, and PHP are so important is key to understanding the paradigm shift. Unlike applications from the previous paradigm, web applications are not released in one to three year cycles. They are updated every day, sometimes every hour. </li></ul>Why Scripting Languages Matter
  16. 16. Agile programming languages <ul><li>We really should stop </li></ul><ul><li>calling them </li></ul><ul><li>&quot;scripting&quot; languages. </li></ul><ul><li>&quot;Agile&quot; languages </li></ul><ul><li>would be more accurate. </li></ul>Kevin Altis and Ward Cunningham
  17. 17. Python - a great agile programming language! <ul><li>Powerful </li></ul><ul><li>Easy-to-learn </li></ul><ul><li>Easy-to-use </li></ul><ul><li>Open-Source </li></ul><ul><li>&quot;Python&quot; from </li></ul><ul><li>&quot;Monty Python's Flying Circus&quot; </li></ul>
  18. 18. Python language features <ul><li>Derived from ABC, Modula-3, and C </li></ul><ul><li>Object-Oriented </li></ul><ul><li>Dynamically typed </li></ul><ul><li>Interpreted </li></ul><ul><li>Cross-platform (Unix, Windows, etc.) </li></ul><ul><li>Extensible </li></ul><ul><li>Flexible </li></ul>
  19. 19. Python's most obvious feature <ul><li>Uses indentation as a control structure </li></ul>no DO.. END no BEGIN..END no { .. }
  20. 20. Indentation as a control-structure <ul><li>for i in range(20): </li></ul><ul><li>if i%3 == 0: </li></ul><ul><li>print i </li></ul><ul><li>if i%5 == 0: </li></ul><ul><li>print &quot;Bingo!&quot; </li></ul><ul><li>print &quot;---&quot; </li></ul>0 Bingo! --- --- --- 3 --- --- --- 6 --- --- --- 9 --- --- --- 12 --- --- --- 15 Bingo! --- --- --- 18 --- ---
  21. 21. Sample Python Code <ul><li>See the handouts distributed with this presentation. </li></ul>For a quick overview of Python's features:
  22. 22. Python's advantages <ul><li>Productivity and Ease-Of-Use </li></ul><ul><li>Maintainability </li></ul><ul><li>Flexibility (OO & functional programming) </li></ul><ul><li>Power </li></ul><ul><li>Plays well with other languages </li></ul><ul><ul><li>Jython compiles to Java byte code </li></ul></ul><ul><li>Extensible </li></ul><ul><ul><li>Easy to extend with, or call from, C </li></ul></ul>
  23. 23. Python – some history <ul><li>Developed by </li></ul><ul><li>Guido van Rossum </li></ul><ul><li>in 1991. </li></ul>A fan of Monty Python's Flying Circus
  24. 24. Guido van Rossum <ul><li>Python BDFL - Benevolent Dictator for Life </li></ul><ul><li>1999 - Dr. Dobb's Journal Excellence in Programming Awards </li></ul><ul><li>2002 – Free Software Foundation (FSF) Award for the Advancement of Free Software </li></ul>
  25. 25. &quot;Doctor Fun has the dubious distinction of being the first web cartoon. Doctor Fun was not, however, the first cartoon on the Internet.&quot; - http://
  26. 26. T-shirt Slogan <ul><li>Python: </li></ul><ul><li>Programming the way Guido indented it </li></ul>
  27. 27. Who is using Python? What are they doing with it? <ul><li>Industrial Light & Magic , maker of the Star Wars films, uses Python extensively in the computer graphics production process. </li></ul><ul><li>Disney Feature Length Animation uses Python for its animation production applications. </li></ul>
  28. 28. <ul><li>Google , a leading internet search engine, is powered by Python. </li></ul><ul><li>Yahoo uses Python for its groups site. </li></ul><ul><li>The Inktomi (formerly Infoseek, now part of Yahoo) search engine uses Python. </li></ul><ul><li>IBM and Philips have used Python to create the business practice logic for factory tool control applications. </li></ul>
  29. 29. <ul><li>NASA uses Python in several large projects, including a CAD/CAM system and a graphical workflow modeler used in planning space shuttle missions. </li></ul><ul><li>The National Institutes of Health (USA) and Case Western Reserve University are building cutting-edge genetic analysis software with Python. </li></ul>
  30. 30. <ul><li>The National Weather Service (USA) uses Python to prepare weather forecasts. </li></ul><ul><li>Python is also used for this purpose at the Swedish Meteorological and Hydrological Institute and at TV4 Sweden . </li></ul><ul><li>Chandler , the new open-source cross-platform Personal Information Manager being developed by Mitch Kapor, is being written in Python and wxWindows. </li></ul>
  31. 31. <ul><li>Lawrence Livermore National Laboratories is basing a new numerical engineering environment on Python. </li></ul><ul><li>The Theoretical Physics Division at Los Alamos National Laboratory uses Python to control large-scale physics codes on massively parallel supercomputers, high-end servers, and clusters. </li></ul>
  32. 32. <ul><li>US Navy uses Python & Zope for a web based workflow system </li></ul><ul><li>US Dept. of Agriculture - Python & Zope for massive collaboration </li></ul>Should we be using Python? ....
  33. 33. Issues to Consider when Evaluating a Programming Language Let's look at some...
  34. 34. Are capabilities an issue? <ul><li>&quot;Batteries included&quot; philosophy </li></ul><ul><li>Standard distribution includes extensive module library </li></ul><ul><li>Many other modules available </li></ul>Frank Stajano
  35. 35. The Python Standard Library <ul><li>GUI </li></ul><ul><li>strings </li></ul><ul><li>regular expressions </li></ul><ul><li>database connectivity </li></ul><ul><li>HTTP, CGI, HTML, XML </li></ul><ul><li>numeric processing </li></ul><ul><li>debugger </li></ul><ul><li>object persistence </li></ul>
  36. 36. Is execution speed an issue? <ul><li>Modern processors generally make language speed a non-issue </li></ul><ul><li>Many applications are limited by speed of database or network connection, not programming language </li></ul><ul><li>Ease-of-use makes implementing optimization algorithms easier – possible to beat even C programs </li></ul><ul><li>Easy to write interface to C extension modules for optimization </li></ul>Probably 10 times slower than a system language, but ...
  37. 37. <ul><li>&quot;In terms of run time and memory consumption, scripting languages often turn out better than Java and not much worse than C or C++.&quot; </li></ul>An empirical comparison of C, C++, Java, Perl, Python, Rexx, and Tcl for a search/string-processing program University of Karlsruhe, Germany Technical Report 2000-5, March 10, 2000 http://
  38. 38. <ul><li>&quot;It might seem that the typeless nature of scripting languages could allow errors to go undetected, but in practice scripting languages are just as safe as system programming languages.&quot; </li></ul><ul><li>&quot;Scripting: Higher Level Programmingfor the 21st Century&quot; by John K. Ousterhout </li></ul><ul><li>IEEE Computer magazine, March 1998 -- </li></ul>Is dynamic typing an issue?
  39. 39. <ul><li>&quot;I'd been a statically typed bigot for quite a few years. Four years ago I got involved with Extreme Programming. ... I liked the emphasis it put on testing. </li></ul><ul><li>About two years ago I noticed I was depending less and less on the type system for safety. My unit tests were preventing me from making type errors. </li></ul><ul><li>So I tried writing some applications in Python, and then Ruby. I found that type issues simply never arose. My unit tests kept my code on the straight and narrow. I simply didn't need static type checking.&quot; </li></ul><ul><ul><li>Robert C. Martin </li></ul></ul>
  40. 40. Is productivity an issue? <ul><li>&quot;5-10 times productivity (really!)&quot; </li></ul><ul><li>Bruce Eckel </li></ul><ul><li>&quot; I find that I'm able to program about three times faster [in Python] than I could in Java, and I was able to program in Java about three times faster than I could in C .&quot; </li></ul><ul><li>Andy Hertzfeld </li></ul><ul><li>&quot;The results indicate that, for the given programming problem, 'scripting languages' (Perl, Python, Rexx, Tcl) are more productive than conventional languages.&quot; </li></ul><ul><li>University of Karlsruhe, Germany, Technical Report 2000-5, March 2000 </li></ul>
  41. 41. <ul><li>When a 20,000 line project went to approximately 3,000 lines overnight, and came out being more flexible and robust ... I realized I was on to something really good. </li></ul><ul><ul><ul><ul><ul><li>-- Matthew &quot;Glyph&quot; Lefkowitz </li></ul></ul></ul></ul></ul><ul><li>...the lines of Python code were 10% of the equivalent C++ code. </li></ul><ul><ul><ul><ul><ul><li>-- Greg Stein , eShop </li></ul></ul></ul></ul></ul>
  42. 42. &quot;Programming is fun again!&quot; <ul><li>Over and over on comp.lang.python there are messages: </li></ul><ul><ul><li>&quot;Now that I've discovered Python, I enjoy programming again!&quot; </li></ul></ul><ul><li>&quot;Now I am back programming in Java because the projects I'm working on call for it. But I wish I was programming in Ruby or Python ...&quot; </li></ul><ul><li>Robert C. Martin </li></ul>
  43. 43. Is maintainability an issue? <ul><li>&quot;I realized that the flexibility of dynamically typed languages makes writing code significantly easier. Modules are easier to write, and easier to change.&quot; </li></ul><ul><ul><li>Robert C. Martin -- </li></ul></ul><ul><li>&quot;Python excels at rapid creation of maintainable code&quot; </li></ul><ul><ul><li>Bruce Eckel </li></ul></ul>
  44. 44. Is weirdness an issue? <ul><li>&quot;Python's use of whitespace stopped feeling unnatural after about twenty minutes. </li></ul><ul><li>I just indented code, pretty much as I would have done in a C program anyway, and it worked.&quot; </li></ul><ul><ul><ul><ul><ul><li>Eric S. Raymond </li></ul></ul></ul></ul></ul>
  45. 45. How weird is it, really? <ul><li>&quot;Most people who use Python consider the indentation syntax to be an important, if not downright critical, feature of the language. It forces you to write readable code, which in turn fosters code maintainability. It's a big win, once you get past the initial shock. </li></ul><ul><li>In any structured programming language, the indentation of blocks really does mean something. Most Python users think that enforcing consistency in indentation is not only good software engineering, it's simple common sense. The end result is code that is so well laid out that it resembles something akin to poetry.&quot; </li></ul>Mark Lutz, author of Programming Python
  46. 46. Is support an issue? <ul><li>Python is an &quot;open-source&quot; language. </li></ul><ul><li>It has no vendor. </li></ul><ul><li>Does that mean we'll have support problems? </li></ul><ul><li>What about... </li></ul><ul><ul><li>Vendor longevity? </li></ul></ul><ul><ul><li>Consulting & training support? </li></ul></ul><ul><ul><li>Books and reference materials? </li></ul></ul><ul><ul><li>Tools? IDEs, debuggers, screen-painters? </li></ul></ul>
  47. 47. What is &quot;Open-Source&quot;? <ul><li>a distribution license for source code </li></ul><ul><ul><li>source code is available without $$$ charge </li></ul></ul><ul><ul><li>code may be changed, customized, enhanced </li></ul></ul><ul><ul><li>GPL – Gnu Public License </li></ul></ul><ul><ul><li>Python license – unlike the GPL, you may distribute a modified version without making your changes open source. </li></ul></ul><ul><li>a development style and a culture... </li></ul>
  48. 49. The Cathedral & the Bazaar <ul><li>Linux is subversive. Who would have thought ... that a world-class operating system could coalesce as if by magic out of part-time hacking by several thousand developers scattered all over the planet, connected only by the tenuous strands of the Internet? </li></ul><ul><li>Certainly not I... I believed there was a certain critical complexity above which a more centralized, a priori approach was required. ... the most important software needed to be built like cathedrals, carefully crafted by individual wizards or small bands of mages working in splendid isolation, with no beta to be released before its time. </li></ul>
  49. 50. The Cathedral & the Bazaar <ul><li>The Linux style of development came as a surprise. No quiet, reverent cathedral-building here—rather, the Linux community seemed to resemble a great babbling bazaar of differing agendas and approaches out of which a coherent and stable system could seemingly emerge only by a succession of miracles. </li></ul><ul><li>The Linux world not only didn't fly apart in confusion -- it seemed to go from strength to strength at a speed barely imaginable to cathedral-builders. </li></ul>
  50. 51. Some open-source products <ul><li>Linux </li></ul><ul><li>Apache </li></ul><ul><li>MySql </li></ul><ul><li>PHP | Perl | Python </li></ul>Apache has overwhelmingly dominated the Web server market since 1996. PHP is the most popular Apache module, running on almost 10 million domains (over a million IP addresses). &quot;MySQL threatens to do for databases what Linux has done for operating systems.&quot; – Tim O'Reilly &quot;LAMP&quot;
  51. 52. Is Open-Source software used in the Federal Government? <ul><li>See earlier list of Python users </li></ul><ul><ul><ul><li>NIH, NASA, Navy, Agriculture, Weather Service </li></ul></ul></ul><ul><li>In 2002, a Mitre study found 115 FOSS products in use in DoD </li></ul><ul><ul><ul><ul><ul><li> </li></ul></ul></ul></ul></ul>Why would a Federal agency use open-source software? ...
  52. 53. <ul><li>Government Computer News November 20, 2000 </li></ul><ul><li>The NASA Acquisition Internet Service (NAIS) development team adopted open-source software several years ago and we plan to expand its use in the agency-wide procurement system. </li></ul><ul><li>We were using a proprietary Web development application that promised interoperability with another vendor’s database software. It failed to interoperate, however... Then we discovered Perl and have been using it for the last five years to develop and support all NAIS applications. Recently, price restructuring for a commercial DBMS threatened to consume most of the NAIS budget. We decided to convert NAIS to MySQL. Our tests showed MySQL could perform NAIS functions faster. Cost of the optional technical support was about 1 percent of that for the commercial product. </li></ul><ul><li>Technical support for MySQL has been excellent when we needed it, plus there are hundreds of Web sites that offer free help and support for such open-source products. We plan to evaluate the Apache HTTP Server to correct limitations of the commercial Web server we currently use. </li></ul>
  53. 54. eGov & Open-Source <ul><li>Center of Open Source & Government   </li></ul><ul><ul><li>( ) </li></ul></ul><ul><li>EGOVOS - high-level international conference on OSS (&quot;Libre Software&quot;), interoperability and open standards in government </li></ul><ul><ul><li>October 2002 & March 2003 - Washington, DC </li></ul></ul><ul><ul><li>EGOVOS3  - 24-26 November, 2003 at UNESCO headquarters in Paris </li></ul></ul>
  54. 55. <ul><li>The Open Source Reference Book 2003 - What Local/National Governments, the Defense Establishment, and The Global 1000 Need To Know About Open Source Software ( November 2003) </li></ul><ul><ul><li>... will provide a Generally Regarded As Safe (GRAS) list of Open Source software to identify mature and useable Open Source projects </li></ul></ul><ul><ul><li>... will list Open Source software that is NIAP* or Common Criteria evaluated </li></ul></ul>*NIAP: National Information Assurance Partnership – NIST security certification
  55. 56. So... Is Open-Source Safe ? <ul><li>Vendors and products vary widely in both the commercial and open-source arena. </li></ul><ul><li>The fact that a piece of software is commercial is no guarantee of its quality, or of its vendor's long-term survival. </li></ul><ul><li>The best open-source software is as good as the best commercial software. </li></ul>
  56. 57. <ul><li>Each product and vendor should be evaluated on its own merits, regardless of whether it is commercial or open-source. </li></ul><ul><li>Python is in the same league as the best software anywhere, commercial or open-source. </li></ul>The Bottom Line
  57. 58. Is vendor longevity an issue? <ul><li>What if Guido got run over by a bus? </li></ul>
  58. 59. The Python Software Foundation <ul><li>A non-profit organization for advancing open-source technology related to Python </li></ul><ul><li>Holds Python's intellectual property rights. </li></ul><ul><li>Produces the core Python distribution, available to the public free of charge. </li></ul><ul><li>Establishes PSF licenses, ensuring the rights of the public to freely obtain, use, redistribute, and modify intellectual property held by the PSF. </li></ul>
  59. 60. Is mindshare an issue? <ul><li>International Python Conference </li></ul><ul><ul><li>IPC - in USA since 1992 </li></ul></ul><ul><li>EuroPython conference </li></ul><ul><ul><li>in Europe since 2002 </li></ul></ul><ul><li>Python for Scientific Computing Workshop </li></ul><ul><ul><li>SciPy - in USA since 2002 </li></ul></ul>The Python community is very active and growing rapidly
  60. 61. Newsgroup Activity comp.lang.* December 2002 <ul><li>java 26953 </li></ul><ul><li>c++ 19913 </li></ul><ul><li>c 13874 </li></ul><ul><li>perl 10486 </li></ul><ul><li>python 9647 </li></ul><ul><li>basic 7909 </li></ul><ul><li>ruby 6466 </li></ul><ul><li>lisp 6132 </li></ul><ul><li>tcl 5256 </li></ul><ul><li>pascal 4229 </li></ul><ul><li>smalltalk 2398 </li></ul><ul><li>fortran 2355 </li></ul><ul><li>cobol 1845 </li></ul>Statistics compiled by Aaron K. Johnson.
  61. 62. TIOBE Popularity of Programming Languages Index July 2003 based on the number of hits returned by a Google search <ul><li>1 Java 44.3 </li></ul><ul><li>2 C 36.8 </li></ul><ul><li>3 C++ 33.2 </li></ul><ul><li>4 Perl 18.3 </li></ul><ul><li>5 (Visual) Basic 15.5 </li></ul><ul><li>6 PHP 7.6 </li></ul><ul><li>7 SQL 6.0 </li></ul><ul><li>8 C# 3.5 </li></ul><ul><li>9 JavaScript 3.3 </li></ul><ul><li>10 Delphi/Pascal/Kylix 3.1 </li></ul><ul><li>11 Python 2.6 </li></ul><ul><li>12 COBOL 2.3 </li></ul><ul><li>13 SAS 2.2 </li></ul><ul><li>14 Fortran 1.9 </li></ul>Index is available at
  62. 63. Is online support an issue? <ul><li>comp.lang.python -- Outstanding!! </li></ul><ul><li> </li></ul><ul><li>?&group=comp.lang.python </li></ul>
  63. 64. Consulting and Training Resources? <ul><li>Not much! </li></ul><ul><li>Python is probably too easy-to-learn and easy-to-use to support much of a training/ consulting industry. You can learn it out of a book! </li></ul><ul><li>A couple of useful consulting resources... </li></ul><ul><ul><li>Zope Corp. </li></ul></ul><ul><ul><li>Fourthought , Inc. - XML tools for Python and XML and web-based applications. </li></ul></ul>
  64. 65. Is Ease-of-Learning an issue? <ul><li>Python is famously easy to use and easy to learn. </li></ul><ul><li>I talked my colleagues into using Python for our Computer Science 1 course this fall. ... In the past I would be swamped during office hours with students wanting help deciphering C++ compiler errors. This semester almost nobody has stopped by for syntax issues. </li></ul><ul><ul><ul><ul><ul><li>-- Dave Reed on Python In Education mailing list </li></ul></ul></ul></ul></ul>
  65. 66. Books & Reference Materials?
  66. 67. Online Materials? <ul><li>Python distribution includes: </li></ul><ul><ul><li>Tutorial, Language Reference </li></ul></ul><ul><ul><li>Extensive Standard Library documentation </li></ul></ul><ul><li>&quot;How to Think Like a Computer Scientist with Python&quot; </li></ul><ul><li>&quot;Python Programming – an Introduction to Computer Science&quot; </li></ul><ul><li>&quot;Dive Into Python&quot; </li></ul><ul><li>Too many others to list... </li></ul>
  67. 68. Tools? - IDEs <ul><li>IDLE comes with Python </li></ul><ul><li>WingIDE – excellent IDE with visual debugger </li></ul>$35 and $180 --
  68. 69. <ul><li>Visual Python </li></ul><ul><li>Python plug-in for Visual Studio .NET. </li></ul><ul><li>Python-specific features within the familiar Visual Studio environment. </li></ul><ul><li>Visual Python integrates seamlessly with Visual Studio .NET, allowing programmers to leverage features of Microsoft's popular development tool suite. </li></ul><ul><li> </li></ul>
  69. 70. Tools? – Screen Painters <ul><li>A screenshot of wxDesigner </li></ul>
  70. 71. What Do the Experts Think of Python?
  71. 72. Bruce Eckel <ul><li>His book Thinking in C++ was given the Software Development Jolt Award for best book published in 1995. </li></ul>Thinking in Java received Java World Reader's Choice Award and Java World Editor's Choice Award for best book, the Java Developer's Journal Editor's Choice Award for books, the Software Development Productivity Award in 1999, the third edition received the Software Development Magazine Jolt award for best technical book, 2002. One of &quot;the industry's leading lights&quot; ( Windows Tech Journal , September 1996).
  72. 73. Why I Love Python © 2001 Bruce Eckel MindView, Inc. Training & Consulting 5343 Valle Vista La Mesa, CA 91941 [email_address]
  73. 74. <ul><li>The language you speak affects what you can think. &quot;Python fits my brain.&quot; </li></ul><ul><li>Python excels at rapid creation of maintainable code </li></ul><ul><li>Programmer productivity is the most important thing. 5-10 times productivity (really!) </li></ul>
  74. 75. <ul><li>Simplicity really does make a difference. </li></ul><ul><li>I can remember many Python idioms because they’re simpler. </li></ul><ul><li>One more reason I program faster in Python. </li></ul><ul><ul><li>I still have to look up how to open a file every time I do it in Java. </li></ul></ul>
  75. 76. Python & “The Tipping Point” <ul><li>It is possible to write programs to automate every task. But you don’t. </li></ul><ul><li>Python makes it easy enough </li></ul>
  76. 77. Eric S. Raymond <ul><li>The Cathedral and the Bazaar </li></ul><ul><ul><li> -bazaar/cathedral-bazaar/ </li></ul></ul><ul><li>The New Hacker's Dictionary </li></ul><ul><ul><li> </li></ul></ul><ul><li>Homesteading the Noosphere </li></ul><ul><ul><li> </li></ul></ul>Well-known Unix guru, Linux advocate, and author
  77. 78. <ul><li>This could be an opportunity to get some hands-on experience with Python... </li></ul><ul><li>I charged ahead and roughed out some code ... </li></ul> Why Python?
  78. 79. <ul><li>I noticed I was generating working code nearly as fast as I could type. When you're writing working code nearly as fast as you can type, it generally means you've achieved mastery of the language. But that didn't make sense, because it was still day one ... </li></ul><ul><li>This was my first clue that, in Python, I was actually dealing with an exceptionally good design. </li></ul>
  79. 80. <ul><li>Not that it took me very long to learn the feature set. </li></ul><ul><li>This reflects another useful property of Python: it is compact -- you can hold its entire feature set (and at least a concept index of its libraries) in your head. </li></ul>
  80. 81. <ul><li>The long-term usefulness of a language comes from how well and how unobtrusively it supports the day-to-day work of programming, which consists not of writing new programs, but mostly reading and modifying existing ones. </li></ul><ul><li>So the real punchline of the story is this: weeks and months after writing fetchmailconf [my Python program], I could still read the code and grok what it was doing without serious mental effort. </li></ul>
  81. 82. Martin C. Brown <ul><li>Author and Perl expert </li></ul><ul><ul><li>Perl: The Complete Reference </li></ul></ul><ul><ul><li>Perl Annotated Archives </li></ul></ul><ul><li>... and ... ... and ... </li></ul>
  82. 83. Nicholas Petreley ComputerWorld columnist <ul><li>One of my favorite programming languages is Python. It seems I don't go a week these days without someone asking me what I know about Python, so it seems to be gaining quite a following in mainstream IT. </li></ul><ul><li>November, 2002 </li></ul>
  83. 84. The Bottom Line... <ul><li>&quot;Use the Best Tool for the Job: Put Both a Scripting and Systems Language in Your Toolbox&quot;- Bill Venners </li></ul><ul><li> </li></ul><ul><li>Python would be a useful tool in the toolboxes of our developers, DBAs, and LAN administrators, </li></ul><ul><li>for situations where.... </li></ul>
  84. 85. <ul><li>A command-language is too under-powered, and a systems programming language would be overkill. </li></ul><ul><li>Speed and minimizing effort are important </li></ul><ul><ul><li>One-time, throw-away programs </li></ul></ul><ul><ul><li>Internal utilities </li></ul></ul><ul><ul><li>Prototyping </li></ul></ul><ul><ul><li>Test scaffolding </li></ul></ul>
  85. 86. <ul><li>Cross-platform portability is important </li></ul><ul><ul><li>System administrators need learn only one scripting language </li></ul></ul><ul><ul><li>Prototype/develop on one platform, deploy on another (e.g. Windows NT and Unix) </li></ul></ul><ul><li>Readability & maintainability are important </li></ul><ul><ul><li>XML processing </li></ul></ul><ul><ul><li>The Python people also piped up to say “everything's just fine here” but then they always do. I really must learn that language. </li></ul></ul><ul><ul><li>XML Is Too Hard For Programmers </li></ul></ul><ul><ul><ul><li>Tim Bray, co-author of the original XML 1.0 spec </li></ul></ul></ul>
  86. 87. <ul><li>Ease-of-learning is important </li></ul>An application is written in four different languages (Java, C, Perl, and Unix shell-script) because it was built by four different developers who were expert in four different languages. Everybody knows this is a problem, but nobody has time to learn another language. One solution -- a single common language that is both powerful enough to handle a wide variety of tasks, and easy enough to learn quickly and easily.
  87. 88. More Online Information <ul><li> is the Python home page </li></ul><ul><li>Chapter 1 of Internet Programming with Python is available online. It discusses reasons for using Python. </li></ul><ul><ul><li> </li></ul></ul><ul><li>Python Compared to Other Languages </li></ul><ul><ul><li>http:// </li></ul></ul>
  88. 89. The End Questions? Comments?