Created
February 20, 2019 15:19
-
-
Save jookyboi/0c3dc122bede13b937d5baf9420b81fb to your computer and use it in GitHub Desktop.
Example gist for Cacher
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class HelloWorld { | |
public static void main(String[] args) { | |
// Prints "Hello, World" to the terminal window. | |
System.out.println("Hello, World"); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern crate serde; // 1.0.85 | |
extern crate serde_json; // 1.0.37 | |
use serde::Serialize; | |
fn test(a: impl Serialize) { | |
println!("{}", serde_json::to_string_pretty(&a).unwrap()); | |
} | |
fn main() { | |
test(25u32); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment