MCPcopy Create free account
hub / github.com/douchuan/algorithm / plus

Function plus

tests/test_sparse_vec.rs:32–39  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

30
31#[test]
32fn plus() {
33 let (a, b) = create();
34 let c = a + b;
35 let expect = vec![0.0, 0.0, 0.0, 1.1, 0.9, 0.0, 0.0, 0.0, 0.0, 0.75];
36 for (i, &v) in expect.iter().enumerate() {
37 assert_relative_eq!(v, c.get(i),);
38 }
39}
40
41#[test]
42fn sub() {

Callers

nothing calls this directly

Calls 2

createFunction · 0.85
iterMethod · 0.45

Tested by

no test coverage detected