rustkell

Crates.iorustkell
lib.rsrustkell
version0.2.2
sourcesrc
created_at2017-10-04 12:13:52.530567
updated_at2017-10-04 15:39:33.65782
descriptionRustkell is haskell like functions in rust.
homepagehttps://github.com/AnickaBurova/rustkell
repositoryhttps://github.com/AnickaBurova/rustkell
max_upload_size
id34377
size8,524
(AnickaBurova)

documentation

https://docs.rs/rustkell/0.1.0/rustkell/

README

Rustkell is haskell like functions in rust. Build Status Crates.io

More functions will come as I will need them.

Documentation

  • tails: The tails function returns all final segments of the list, longest first.

Usage

Cargo.toml

[dependencies]
rustkell = "0.2"

main.rs

extern crate rustkell;

use rustkell::DataList;
use std::iter::Iterator;

fn main() {
    let v = vec![1,2,3,4];
    for t in v.tails() {
        println!("{:?}", t);
    }
}

Output:

> [1, 2, 3, 4]  
> [2, 3, 4]  
> [3, 4]  
> [4]  
> []  

License

Licensed under the MIT license, see LICENSE

Commit count: 16

cargo fmt