From 067b3d6f42157c1df98f8e5a168b715ad16ebd2b Mon Sep 17 00:00:00 2001 From: Michele Sessa Date: Wed, 3 Aug 2022 16:58:30 +0100 Subject: [PATCH] docs(copy, tic_tac_toe): Improve code example and console output by putting output only in the console output and removing it from the code as comment --- subjects/copy/README.md | 4 ---- subjects/tic_tac_toe/README.md | 4 +--- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/subjects/copy/README.md b/subjects/copy/README.md index 480d45c8..9108c6a0 100644 --- a/subjects/copy/README.md +++ b/subjects/copy/README.md @@ -40,13 +40,9 @@ fn main() { let c = vec![1, 2, 4, 5]; println!("{:?}", nbr_function(a)); - // output : (0, 1.0, inf) println!("{:?}", str_function(b)); - // output : ("1 2 4 5 6", "2.718281828459045 7.38905609893065 54.598150033144236 148.4131591025766 403.4287934927351") println!("{:?}", vec_function(c)); - // output : ([1, 2, 4, 5], [0.0, 0.6931471805599453, 1.3862943611198906, 1.6094379124341003]) } - ``` And its output: diff --git a/subjects/tic_tac_toe/README.md b/subjects/tic_tac_toe/README.md index 81287f37..6ba767f0 100644 --- a/subjects/tic_tac_toe/README.md +++ b/subjects/tic_tac_toe/README.md @@ -40,7 +40,7 @@ fn main() { vec!["X", "#", "X"] ]) ); - // "Tie" + println!( "{:?}", tic_tac_toe(vec![ @@ -49,7 +49,6 @@ fn main() { vec!["#", "O", "X"] ]) ); - // "player O won" let dig = vec![ vec!["O", "O", "X"], @@ -58,7 +57,6 @@ fn main() { ]; println!("{:?}",tic_tac_toe(dig)); - // "player X won" } ```