Guessing Gameを読み進める2
Guessing Gameを読み進める。 ( Generating a secret numberを読んだ。 )
Cargo.toml
にrand="0.3.0"
を追記すると、cargo build
するだけで、関連するライブラリを引っ張ってきてくれる。便利。
$ cargo build Updating registry `https://github.com/rust-lang/crates.io-index` Downloading rand v0.3.15 Downloading libc v0.2.19 Compiling libc v0.2.19 Compiling rand v0.3.15 Compiling guessing_game v0.1.0 (file:///Users/miura/work/git-work/exercises/The_Rust_Programming_Language/guessing_game) Finished debug [unoptimized + debuginfo] target(s) in 4.31 secs