algorithmz 0.9.0

This is the corresponding implemenation of the python module of the same name.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use algorithmz::string::{fizzbuzz,Buzz};

#[test]
fn test_fizzbuzz() {
    let result = fizzbuzz(5);
    assert_eq!(result, vec![Buzz::Number(1),Buzz::Number(2),Buzz::Text(String::from("Fizz")),Buzz::Number(4),Buzz::Text(String::from("Buzz"))]);
}

#[test]
fn test_fizzbuzz_empty() {
    let result = fizzbuzz(0);
    assert_eq!(result,Vec::new());
}