#hello-world #generate #string #print #hello

hello-sayer

Rust library to generate and print hello world strings

1 stable release

1.0.0 Feb 15, 2025

#569 in Command-line interface

Download history 119/week @ 2025-02-12 8/week @ 2025-02-19 3/week @ 2025-02-26

130 downloads per month

LGPL-3.0

3KB

hello-sayer

A Rust library for generating and printing Hello world messages.

Usage

Install the library with:

cargo add hello-sayer

The following functions are included:

  • generate_hello_message() -> &'static str - Returns "Hello world!" as a string slice
  • say_hello() -> () - Prints the string returned by generate_hello_message
  • say_hello_string(&str string) -> () - Prints the string slice given.
  • say_hello_handler(fn() -> &'static str) -> () - Prints the string slice returned by the given handler.

Is this useless?

Yes. You can achieve the same functionality by just using the println! macro.

No runtime deps