Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2019
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.16 KB | None | 0 0
  1. fn curry (x: i64) -> impl Fn(i64) -> Box<Fn(i64) -> i64> {
  2. move |a: i64| { Box::new(move |b: i64| x + a + b) }
  3. }
  4.  
  5. fn main() {
  6. println!("{}", curry(3)(4)(5));
  7. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement