mirror of
https://git.aramjonghu.dev/AramJonghu/rustlings.git
synced 2026-09-06 18:13:29 +02:00
Clean up and unify exercises
This commit is contained in:
@@ -1,13 +1,8 @@
|
||||
// from_str.rs
|
||||
//
|
||||
// This is similar to from_into.rs, but this time we'll implement `FromStr` and
|
||||
// return errors instead of falling back to a default value. Additionally, upon
|
||||
// implementing FromStr, you can use the `parse` method on strings to generate
|
||||
// an object of the implementor type. You can read more about it at
|
||||
// https://doc.rust-lang.org/std/str/trait.FromStr.html
|
||||
//
|
||||
// Execute `rustlings hint from_str` or use the `hint` watch subcommand for a
|
||||
// hint.
|
||||
|
||||
use std::num::ParseIntError;
|
||||
use std::str::FromStr;
|
||||
|
||||
Reference in New Issue
Block a user