The words Under construction in black text on a yellow background with diagonal black stipes surrounding it
I'm in the process of moving my site. It's still a work in progress. Please excuse the mess and broken links.

Read STDIN in Rust

TODO: Pull subtitle into page object
Code
use std::io;

fn main() -> io::Result<()> {
    let stdin = io::read_to_string(io::stdin())?;
    println!("Stdin was:");
    println!("{stdin}");
    Ok(())
}

Debugging Stuff

I'm moving stuff around right now. All this below is helping me figure out where to put stuff

        -- title

Read STDIN in Rust

-- code

use std::io;

fn main() -> io::Result<()> {
    let stdin = io::read_to_string(io::stdin())?;
    println!("Stdin was:");
    println!("{stdin}");
    Ok(())
}


-- categories
-- Rust 

-- metadata
-- date: 2023-08-22 01:08:56
-- id: 2ukgcm2v
-- site: aws
-- type: snippet 
-- status: published