io_capitalize 0.1.0

A crate to simplfy Rust,s IO scripts as similar to Python.
Documentation
  • Coverage
  • 0%
    0 out of 7 items documented0 out of 6 items with examples
  • Size
  • Source code size: 3.71 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.15 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • Repository
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • Knoex-Softwares

io_capitalize crate for Rust

This crate will make writing inputs in Rust alot easier as Python.

How to Use:

use io_capitalize::*;

// Import the crate to use.

fn main() {

let mut ask = input_str("How are you? ).to_lowercase;

if ask.contains(good) || ask.contains(nice) || ask.contains(cool) {

    ask = "good".to_string();
    // If you want to reassign your muttable variable, you must convert it to String. (&str aren't compatible.)

    print!("{}? Nice.", ask.capitalize());
}

else {
    print!("OH!");
}

// See how much simple it is? Also it works with other types by: (input_int) both i64 and i32, (input_float) both f64 and f32, (input_bool) for booleans.
// And the capitalize method is integrated, it is a Python equivalent of .capitalize() string method, useful to have though.

}