diff --git a/solutions/rust/hello-world/1/Cargo.toml b/solutions/rust/hello-world/1/Cargo.toml new file mode 100644 index 0000000..e780cd4 --- /dev/null +++ b/solutions/rust/hello-world/1/Cargo.toml @@ -0,0 +1,9 @@ +[package] +name = "hello_world" +version = "0.1.0" +edition = "2024" + +# Not all libraries from crates.io are available in Exercism's test runner. +# The full list of available libraries is here: +# https://github.com/exercism/rust-test-runner/blob/main/local-registry/Cargo.toml +[dependencies] diff --git a/solutions/rust/hello-world/1/src/lib.rs b/solutions/rust/hello-world/1/src/lib.rs new file mode 100644 index 0000000..5c2db6d --- /dev/null +++ b/solutions/rust/hello-world/1/src/lib.rs @@ -0,0 +1,4 @@ +// &'static is a "lifetime specifier", something you'll learn more about later +pub fn hello() -> &'static str { + "Hello, World!" +}