Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(1)  |  Derive(0)  |  Import(0)

src/p/r/pretzel-1.0.10/pretzel/monad/tests/monad.py   pretzel(Download)
    def test_lift_func(self):
        # lift_func :: (Monad m) => (a0 -> ... -> r) -> (m a0 -> ... -> m r)
        list_add = List.lift_func(lambda a, b: a + b)
        self.assertEqual(list_add(List(0, 1), List(0, 1)), List(0, 1, 1, 2))