News for hackers. Stuff that matters.
Re:Announcing Rust 1.23 by leshow on Thursday January 04, 2018 @01:39PM (#16072824)
I find graphs and trees are common 'exercises' that people do when they try out a new language, but you usually won't be implementing stuff like this day to day. You'd be using a well tested library, not cooking one up yourself.

My advice would be to try and write some 'real world' code instead of programming kattas to get a feel for the language.

Re:Announcing Rust 1.23 by bulldoa on Thursday January 04, 2018 @02:58PM (#16073507)
yeah, but another thing I am worried is that if I want to get a rust job, I should be able to do interview problems in rust, which mostly consist of linked list, tree and graph.
Re:Announcing Rust 1.23 by baq on Thursday January 04, 2018 @04:09PM (#16074110)
you'd use a cell/refcell/box or just wouldn't get this excercise as everyone who got past it in rust know it's not easy and critically it's not supposed to be easy.

it's difficult in rust because recurrent data structures are super hard to reason about in general in terms of borrowing and ownership when AOT compiling and you unfortunately must know this to be efficient at rust; this realization is one of the stages of learning the language.

Re:Announcing Rust 1.23 by steveklabnik on Thursday January 04, 2018 @03:07PM (#16073595)
I would argue that's a terrible interview, as anyone who's in the position to give a Rust job should know this about Rust.
Re:Announcing Rust 1.23 by mmstick on Monday January 08, 2018 @07:00PM (#16102176)
I landed a job w/ Rust, and the programming challenge I was given was a simple C programming challenge to implement a parser to parse gzip headers, to which I did it in both C and Rust.

Nobody hiring for a position that's largely Rust is going to ask you to write linked lists, trees, and graphs. They're going to want you to build something more complex & practical.