Skip to main content

Python Snippets

Project description

Python Snippets

Installation

pip install pysnippets

Usage

Python 2.7.5 (default, Mar  9 2014, 22:15:05)
Type "copyright", "credits" or "license" for more information.

IPython 2.2.0 -- An enhanced Interactive Python.
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: import pysnippets.dictsnippets as dsnippets

In [2]: dsnippets.filter({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'])
Out[2]: {'c': 3, 'd': 4}

In [3]: dsnippets.filter({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'], exec_eval=False)
Out[3]: {'c': 3, 'd': '4'}

In [4]: dsnippets.gets({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'])
Out[4]: [3, 4]

In [5]: dsnippets.gets({'a': 1, 'b': 2, 'c': 3}, ['c', 'd:4'], exec_eval=False)
Out[5]: [3, '4']

In [6]:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pysnippets-1.0.2.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

pysnippets-1.0.2-py2.py3-none-any.whl (4.8 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file pysnippets-1.0.2.tar.gz.

File metadata

  • Download URL: pysnippets-1.0.2.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pysnippets-1.0.2.tar.gz
Algorithm Hash digest
SHA256 cd88a921c35700d73137e57a9e3240c655c9e4e07aba7ce95d22a7e71e86b12e
MD5 8970fec6e702f971ad4d73f1740e80b7
BLAKE2b-256 af446a7850b0dfcbd6c0c94dcd29f3be13c92d6f68865b945f8572b55db4d7df

See more details on using hashes here.

File details

Details for the file pysnippets-1.0.2-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for pysnippets-1.0.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 7399b1f51df7f424859816bc631bad7dd23aed91e1e5b61ac5e15e2a7863ca48
MD5 95122770ef36ffbb26fbcb7d8e8b4915
BLAKE2b-256 1ed34d36e70916b85f69f0111510a272643cf1d3831d910018301ee7d5c3ae79

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page