3 ms·
> The author doesn't really justify why he needed to port the python script to rust in the first place. And they don't need to. When I first learned Rust, I tr
by burntsushi 10y ago
> The author doesn't really justify why he needed to port the python script to rust in the first place.
And they don't need to. When I first learned Rust, I tried to write a `filter` function. Why would I ever do that? I could write `filter` much easier in Python, or heck, just use the `filter` method on iterators that is already in the standard library. I did it because I saw it as an opportunity to learn. I wanted to connect something I knew (`filter`) with something I didn't know (Rust).
- djhworld 10y agoI guess I was getting at the fact that porting the python script that does something very simple is the wrong tool for the job. A good candidate for trying to learn Rust is to find a script or tool that currently has the problems that Rust claims to fix.
- burntsushi 10y agoWhen someone comes to me and says, "I just spent the weekend porting a simple Python web crawler that was working just fine to Rust, and I came across problems x, y and z." What do you think an appropriate response is? Should we berate them for "choosing the wrong tool for the job"? Or should we ask them what they're problems were and help them fix them? I'm not saying we shouldn't have a conversation about which-tools-are-appropriate-when, but when someone is obviously trying to learn, let's put that on the back burner.