Product SiteDocumentation Site

Python for you and me 0.2

Python for you and me

Python for you and me

Edition 1

Logo

Kushal Das

Linux User Group of Durgapur

Legal Notice

Permission is granted to copy, distribute, and/or modify this document under the terms of the Open Publication Licence, Version 1.0, or any later version. The terms of the OPL are set out below.
  1. REQUIREMENTS ON BOTH UNMODIFIED AND MODIFIED VERSIONS

    Open Publication works may be reproduced and distributed in whole or in part, in any medium physical or electronic, provided that the terms of this license are adhered to, and that this license or an incorporation of it by reference (with any options elected by the author(s) and/or publisher) is displayed in the reproduction.
    Proper form for an incorporation by reference is as follows:
    Copyright (c) <year> by <author's name or designee>. This material may be distributed only subject to the terms and conditions set forth in the Open Publication License, vX.Y or later (the latest version is presently available at http://www.opencontent.org/openpub/).
    The reference must be immediately followed with any options elected by the author(s) and/or publisher of the document (see section VI). Commercial redistribution of Open Publication-licensed material is permitted. Any publication in standard (paper) book form shall require the citation of the original publisher and author. The publisher and author's names shall appear on all outer surfaces of the book. On all outer surfaces of the book the original publisher's name shall be as large as the title of the work and cited as possessive with respect to the title.
  2. COPYRIGHT

    The copyright to each Open Publication is owned by its author(s) or designee.
  3. SCOPE OF LICENSE

    The following license terms apply to all Open Publication works, unless otherwise explicitly stated in the document.
    Mere aggregation of Open Publication works or a portion of an Open Publication work with other works or programs on the same media shall not cause this license to apply to those other works. The aggregate work shall contain a notice specifying the inclusion of the Open Publication material and appropriate copyright notice.
    SEVERABILITY. If any part of this license is found to be unenforceable in any jurisdiction, the remaining portions of the license remain in force.
    NO WARRANTY. Open Publication works are licensed and provided "as is" without warranty of any kind, express or implied, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose or a warranty of non-infringement.
  4. REQUIREMENTS ON MODIFIED WORKS

    All modified versions of documents covered by this license, including translations, anthologies, compilations and partial documents, must meet the following requirements:
    1. The modified version must be labeled as such.
    2. The person making the modifications must be identified and the modifications dated.
    3. Acknowledgement of the original author and publisher if applicable must be retained according to normal academic citation practices.
    4. The location of the original unmodified document must be identified.
    5. The original author's (or authors') name(s) may not be used to assert or imply endorsement of the resulting document without the original author's (or authors') permission.
  5. GOOD-PRACTICE RECOMMENDATIONS

    In addition to the requirements of this license, it is requested from and strongly recommended of redistributors that:
    1. If you are distributing Open Publication works on hardcopy or CD-ROM, you provide email notification to the authors of your intent to redistribute at least thirty days before your manuscript or media freeze, to give the authors time to provide updated documents. This notification should describe modifications, if any, made to the document.
    2. All substantive modifications (including deletions) be either clearly marked up in the document or else described in an attachment to the document.
    3. Finally, while it is not mandatory under this license, it is considered good form to offer a free copy of any hardcopy and CD-ROM expression of an Open Publication-licensed work to its author(s).
  6. LICENSE OPTIONS

    The author(s) and/or publisher of an Open Publication-licensed document may elect certain options by appending language to the reference to or copy of the license. These options are considered part of the license instance and must be included with the license (or its incorporation by reference) in derived works.
    A. To prohibit distribution of substantively modified versions without the explicit permission of the author(s). "Substantive modification" is defined as a change to the semantic content of the document, and excludes mere changes in format or typographical corrections.
    To accomplish this, add the phrase 'Distribution of substantively modified versions of this document is prohibited without the explicit permission of the copyright holder.' to the license reference or copy.
    B. To prohibit any publication of this work or derivative works in whole or in part in standard (paper) book form for commercial purposes is prohibited unless prior permission is obtained from the copyright holder.
    To accomplish this, add the phrase 'Distribution of the work or derivative of the work in any standard (paper) book form is prohibited unless prior permission is obtained from the copyright holder.' to the license reference or copy.
Abstract
This book is for the python newbies

Preface
1. രേഖയിലെ കീഴ്‌വഴക്കങ്ങള്‍
1.1. Typographic Conventions
1.2. Pull-quote Conventions
1.3. കുറിപ്പുകളും മുന്നറിയിപ്പുകളും
2. നിങ്ങളുടെ അഭിപ്രായം ദയവായി ഞങ്ങള്‍ക്കു് അയച്ചു തരിക!
1. ഇന്‍സ്റ്റലേഷന്‍ ‍
1.1. വിന്‍‌ഡോസില്‍
1.2. ഗ്നു/ലിനക്സില്‍
2. ഇനി തുടങ്ങാം
2.1. helloworld.py
2.2. ചിട്ടപ്പെടുത്തല്‍
2.3. കമന്‍റ്സ്
2.4. മൊഡ്യൂള്‍സ്
3. വേര്യബിളുകളും ഡാറ്റാടൈപ്പുകളും
3.1. കീ വേര്‍ഡുകളും ഐഡന്‍റിഫയറുകളും
3.2. കീബോര്‍ഡില്‍ നിന്നും ഇന്‍പുട്ട് സ്വീകരിക്കുന്ന വിധം
3.3. ചില ഉദാഹരണങ്ങള്‍
3.3.1. N സംഖ്യകളുടെ ശരാശരി
3.3.2. താപനില പരിവര്‍‌ത്തനം
3.4. ഒരേ സമയം ഒന്നലധികം വേരിയബിളിന് മൂല്യം നല്‍കല്‍
4. ഓപ്പറേറററുകളും എക്സപ്രഷനുകളും
4.1. ഓപ്പറേറേറഴ്സ്
4.2. സാംഖിക ഗണിത ഉദാഹരണങ്ങള്‍
4.3. റിലേഷണല്‍ ഓപ്പറേററര്‍
4.4. ലോജിക്കല്‍ ഓപ്പറേറററുകള്‍
4.5. ഷോര്‍ട്ട് ഹാന്‍റ് ഓപ്പറേററര്‍
4.6. എക്സ്പ്രഷനുകള്‍
4.7. ടൈപ്പ് പരിവര്‍ത്തനം
4.8. evaluateequ.py
4.9. quadraticequation.py
4.10. salesmansalary.py
5. if-else കണ്ട്രോള്‍ ഫ്ളോ
5.1. if പ്രസ്താവന
5.2. Else പ്രസ്താവന
6. ലൂപ്പിംങ്
6.1. While ലൂപ്പ്
6.2. ഫിബനോച്ചി ക്രമം
6.3. പവര്‍ ക്രമം
6.4. ഗുണനപ്പട്ടിക
6.5. കുറച്ച് പ്രിന്‍റിംഗ് ഉദാഹരണങ്ങള്‍
6.6. ലിസ്ററുകള്‍
6.7. For ലൂപ്പ്
6.8. range() function
6.9. Continue പ്രസ്താവന
6.10. Else ലൂപ്പ്
6.11. Game of sticks
7. ഡാറ്റാ ഘടന
7.1. ലിസ്റ്റുകള്‍
7.2. ലിസ്റ്റ് സ്റ്റാക്ക് ക്യൂ എന്നിവയുടെ പ്രയോഗം
7.3. ലിസ്റ്റ് കോമ്പ്രിഹെന്‍ഷന്‍
7.4. ടുപ്പിള്‍സ്
7.5. സെററുകള്‍
7.6. ഡിക്ഷണറികള്‍
7.7. students.py
7.8. matrixmul.py
8. സട്രിംഗ്സ്
8.1. സട്രിംഗുകള്‍ എഴുതാന്‍ ലഭ്യമായ വിവിധ രീതികള്‍
8.2. സ്ട്രിംഗിനെ സ്ട്രിംഗ് ചെയ്യല്‍
8.3. ടെക്സ്ററ് തിരയല്‍
8.4. Palindrome പരിശോധിക്കല്‍
8.5. വാക്കുകളുടെ എണ്ണം
9. ഫങ്ഷനുകള്‍
9.1. ഫങ്ഷന്‍ നിര്‍വചിക്കുന്ന വിധം
9.2. ലോക്കല്‍ വാര്യബിളുകളും ഗ്ളോബല്‍ വാര്യബിളുകളും
9.3. ഡീഫോള്‍ട്ട് ആര്‍ഗ്യുമെന്‍റ് മൂല്യം
9.4. കീവേഡ് ആര്‍ഗ്യുമെന്‍റ്സ്
10. File handling
10.1. File opening
10.2. Closing a file
10.3. Reading a file
10.4. Writing in a file
10.5. copyfile.py
10.6. Random seeking in a file
10.7. Count spaces, tabs and new lines in a file
11. Class
11.1. Your first class
11.2. __init__ method
11.3. Inheritance
11.4. student_teacher.py
11.5. Multiple Inheritance
11.6. Deleting an object
12. Modules
12.1. Introduction
12.2. Importing modules
12.3. Default modules
12.4. Module os
13. കൃതജ്ഞത
A. Revision History