In the Rust book he said
A match expression is made up of arms. An arm consists of a pattern to match against, and the code that should be run if the value given to match fits that arm’s pattern. Rust takes the value given to match and looks through each arm’s pattern in turn.
But the example is very weak (is not the goal of the book)
I am not a native English speaker, maybe is that why this simple phrase is so confusing to me. Even chatgpt didn't give me an answer about that.
What is the Arms Pattern?
Aucun commentaire:
Enregistrer un commentaire