{"id":27197788,"url":"https://github.com/preaction/list-slice","last_synced_at":"2025-04-09T20:29:36.357Z","repository":{"id":32135973,"uuid":"35708671","full_name":"preaction/List-Slice","owner":"preaction","description":"Slice-like operations on lists","archived":false,"fork":false,"pushed_at":"2016-11-12T04:07:02.000Z","size":71,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-04-17T21:17:01.880Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/preaction.png","metadata":{"files":{"readme":"README","changelog":"CHANGES","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-05-16T03:45:20.000Z","updated_at":"2024-04-17T21:17:01.880Z","dependencies_parsed_at":"2022-08-29T04:52:40.403Z","dependency_job_id":null,"html_url":"https://github.com/preaction/List-Slice","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/preaction%2FList-Slice","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/preaction%2FList-Slice/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/preaction%2FList-Slice/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/preaction%2FList-Slice/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/preaction","download_url":"https://codeload.github.com/preaction/List-Slice/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248106855,"owners_count":21048808,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-04-09T20:29:35.737Z","updated_at":"2025-04-09T20:29:36.348Z","avatar_url":"https://github.com/preaction.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"=head1 SYNOPSIS\n\n    use List::Slice qw( head tail );\n\n=head1 DESCRIPTION\n\nThis module provides functions for slicing lists. This is helpful when you\nwant to do a chain of manipulations on a list (map, grep, sort) and then\nslice, without the cumbersome C\u003c(...)[x]\u003e syntax.\n\n=head1 FUNCTIONS\n\n=head2 head\n\n    my @values = head $size, @list;\n\nReturns the first C\u003c$size\u003e elements from C\u003c@list\u003e. If C\u003c$size\u003e is negative, returns\nall but the last C\u003c$size\u003e elements from C\u003c@list\u003e.\n\n    @result = head 2, qw( foo bar baz );\n    # foo, bar\n\n    @result = head -2, qw( foo bar baz );\n    # foo\n\n=head2 tail\n\n    my @values = tail $size, @list;\n\nReturns the last C\u003c$size\u003e elements from C\u003c@list\u003e. If C\u003c$size\u003e is negative, returns\nall but the first C\u003c$size\u003e elements from C\u003c@list\u003e.\n\n    @result = tail 2, qw( foo bar baz );\n    # bar, baz\n\n    @result = tail -2, qw( foo bar baz );\n    # baz\n\n=head1 SEE ALSO\n\nL\u003cList::Util\u003e, L\u003cList::MoreUtils\u003e, L\u003cList::UtilsBy\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpreaction%2Flist-slice","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpreaction%2Flist-slice","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpreaction%2Flist-slice/lists"}