Skip to main content

Record list with handy methods

Project description

rlist

rlist is a small Python library that provides the rlist type (record list), which is a plain Python list extended with a few handy methods for in-place manipulation.
The methods are inspired by the corresponding Ruby array methods.

Documentation: https://maxcode123.github.io/rlist/

Example

from rlist import rlist

people = [
  {"age": 29, "name": "John", "sex": "M"},
  {"age": 67, "name": "Paul", "sex": "M"},
  {"age": 39, "name": "George", "sex": "M"},
  {"age": 18, "name": "Mary", "sex": "F"},
  {"age": 45: "name": "Margaret", "sex":  "F"}
]

people.select(lambda p: p["age"] > 30).reject(lambda p: "l" in p["name"]).map(lambda p: p["sex"])

Installation

pip install record-list

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

record_list-0.2.3.tar.gz (4.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

record_list-0.2.3-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file record_list-0.2.3.tar.gz.

File metadata

  • Download URL: record_list-0.2.3.tar.gz
  • Upload date:
  • Size: 4.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.5.11

File hashes

Hashes for record_list-0.2.3.tar.gz
Algorithm Hash digest
SHA256 0ac825e08d0c9cdafbacf612c5e4e320ecf9c2448f79152e06c05a44c0b98ffa
MD5 5443f2e9c1bfcfb65c11b9b67ab3d3dd
BLAKE2b-256 17e1555a5b30673aceec7552cbbc3f1d7c3fced60529f5f493aa1bcd4565fde4

See more details on using hashes here.

File details

Details for the file record_list-0.2.3-py3-none-any.whl.

File metadata

File hashes

Hashes for record_list-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 4f186145c455856e8d2c7d8e13428d58ec2494825514f7ca1f991cd49d9c95cb
MD5 1fbc3de9f40fe8397a2698aa85ef3e86
BLAKE2b-256 a49f3143cab17539de53439d05e6ba0b68ac5d159cf2d6a9dd9a3995232ada3b

See more details on using hashes here.

Supported by

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