Coder Social home page Coder Social logo

tiny-python-3.6-notebook's Introduction

Note!

This repo is outdated: You probably want

https://github.com/mattharrison/Tiny-Python-3.9-Notebook

Tiny Python 3.6 Notebook

This repository contains the text for the Tiny Python 3.6 Notebook.

Warning, this is not an introduction to Python. Rather it is a notebook containing curated examples for Python 3 as well as the new features found in Python 3.6. It is designed to accompany technical corporate training offered by the author or aid those who want a quick refresher to the Python syntax.

Reviews

This is an awesome python3 resource I share all the time. 🐍🎉 - @nnja (MS Developer Advocate)

I think it's pretty awesome. It's all of the syntax boiled down to just the facts man. - Brian Okken (Host of Test & Code podcast)

It's the perfect follow on to a training course. - Michael Kennedy (Host of Talk Python podcast)

Great Python reference book by @__mharrison__ "Tiny Python 3.6 Notebook" It's NOT a @ProjectJupyter notebook - @okeedoak

Goodness! So thankful for @__mharrison__ and his Tiny Python 3.6 Notebook. Great resource! Go get it… - @__jamesssio__

Tiny #Python notebook for looking up all the basics. I found this a very concise read if you have some prev prog exp - @andreasose

Useful collection of notes on Python 3.6 - @hjelmj

Cool work: a tiny and handy notebook containing notes, tables and examples for Python 3.6. Very much recommended! - @epaillas

I keep a copy on my desk. Excellent resource - @HLIBIndustry

Awesome community work! - @MostafaElzoghbi

Интересный формат книги по #python - @ku_al

Bulk Purchase

If you are interested in purchasing larger amounts (100+) for schools, employees or for use as giveaways/swag at a conference (much better than a tshirt!), get in touch with Matt (matt at metasnake dot com).

Thanks

If you enjoy this content, consider purchasing the physical version. It is a hand laid out version that fits in the pocket and has blank pages in the back for note taking. It is available at Amazon. I'm indebted to those who support my work and write reviews. Thanks!

Feel free to share this repository on social media.

Errors

The author is human and will certainly make errors. You may file a bug and it may be resolved in a future version of the book. I love feedback and would love to hear your ideas on what is missing or could be improved.

Contents

This book covers the syntax in Python up to version 3.6.

License

This content is licensed under the Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0)

https://creativecommons.org/licenses/by-nc-nd/4.0/

tiny-python-3.6-notebook's People

Contributors

fheilmann avatar mattharrison avatar pcampr avatar shadyan avatar uvtc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tiny-python-3.6-notebook's Issues

File Modes table seems incomplete

Hi, I found this tiny python summary very helpful for catching up with the language.

During an online course I stumbled upon the file modes of the 'open()' method. The "r+" and "w+" file modes seem to be missing in this book. The only "+" mode which is mentioned is "w+b".

I think adding the "r+", "w+", "rb+", "a+" and "ab+" modes would be helpful. (Especially the difference between "r+" and "w+" is not obvious.)

From python help:

`
========= ====
Character Meaning


'r' open for reading (default)
'w' open for writing, truncating the file first
'x' create a new file and open it for writing
'a' open for writing, appending to the end of the file if it exists
'b' binary mode
't' text mode (default)
'+' open a disk file for updating (reading and writing)
'U' universal newline mode (deprecated)
========= ====`

From: https://stackoverflow.com/a/23566951
`

r          Opens a file for reading only. The file pointer is placed at the beginning of the file. This is the default mode.
rb        Opens a file for reading only in binary format. The file pointer is placed at the beginning of the file. This is the default mode.
r+        Opens a file for both reading and writing. The file pointer will be at the beginning of the file.
rb+        Opens a file for both reading and writing in binary format. The file pointer will be at the beginning of the file.
w        Opens a file for writing only. Overwrites the file if the file exists. If the file does not exist, creates a new file for writing.
wb        Opens a file for writing only in binary format. Overwrites the file if the file exists. If the file does not exist, creates a new file for writing.
w+        Opens a file for both writing and reading. Overwrites the existing file if the file exists. If the file does not exist, creates a new file for reading and writing.
wb+        Opens a file for both writing and reading in binary format. Overwrites the existing file if the file exists. If the file does not exist, creates a new file for reading and writing.
a        Opens a file for appending. The file pointer is at the end of the file if the file exists. That is, the file is in the append mode. If the file does not exist, it creates a new file for writing.
ab        Opens a file for appending in binary format. The file pointer is at the end of the file if the file exists. That is, the file is in the append mode. If the file does not exist, it creates a new file for writing.
a+        Opens a file for both appending and reading. The file pointer is at the end of the file if the file exists. The file opens in the append mode. If the file does not exist, it creates a new file for reading and writing.
ab+        Opens a file for both appending and reading in binary format. The file pointer is at the end of the file if the file exists. The file opens in the append mode. If the file does not exist, it creates a new file for reading and writing.

`

correct an error

In set methods, the result of "s.issuperset(s2)" should be "All elements of s2 in s". Anyway, this is a great book!

Tiny Notebook is too Tiny

The Tiny Notebook would be easier to read and handle if it were a smidge larger, including the font size.

Current physical size is 6 inches by 4.

Would be nice if it were an inch taller to fit more content vertically (feels too short to me as it is). A half inch wider to have more inner margin space, and to possibly reduce the number of line breaks in tables (though an increase in font size might negate this).

Also, the font is rather small, and the code font particularly so. I find it a bit difficult to read, but I understand it's difficult to fit monospace code examples if the font were made larger. Is there a narrower monospace font available?

A possible drawback to increasing the book's dimensions: it would probably no longer easily fit into a pocket. I don't know if that's something readers want. I personally have no reason to have it in my pocket.

Great Book !

Thank you for the book ! Very good book !

I do have only one question for you. How you create a pdf file or hard book for amazon from rst files ?

And last but not least congratulations for good book !

Context Managers example will not return expected text

>>> def start(env):
...     return '\begin{}'.format(env)

will cause start('center') to return egincenter. You need to escape the backslash and the curly braces like so:

>>> def start(env):
...     return '\\begin{{{}}}'.format(env)

same for end(env):

>>> def end(env):
...      return '\\end{{{}}}'.format(env)

edit:

the same applies for Function Based Context Managers and Class Based Context Managers

Permission to make Anki Cards

Great book - after reading the CC license I'm pretty sure creating Anki Cards wouldn't be allowed, but if it's possible I'd like to.

Thoughts / comments / feelings on this?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.