aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorcodecrafters-bot <hello@codecrafters.io>2024-06-03 10:57:48 +0000
committercodecrafters-bot <hello@codecrafters.io>2024-06-03 10:57:48 +0000
commite554c837db6cbb337d846331cce7057cd33be883 (patch)
treee835a1ff64015b917584445b222d55dde8eb8698 /src
downloadtiny-server-e554c837db6cbb337d846331cce7057cd33be883.tar.xz
tiny-server-e554c837db6cbb337d846331cce7057cd33be883.zip
init [skip ci]
Diffstat (limited to 'src')
-rw-r--r--src/main.rs22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs
new file mode 100644
index 0000000..01f209e
--- /dev/null
+++ b/src/main.rs
@@ -0,0 +1,22 @@
+// Uncomment this block to pass the first stage
+// use std::net::TcpListener;
+
+fn main() {
+ // You can use print statements as follows for debugging, they'll be visible when running tests.
+ println!("Logs from your program will appear here!");
+
+ // Uncomment this block to pass the first stage
+ //
+ // let listener = TcpListener::bind("127.0.0.1:4221").unwrap();
+ //
+ // for stream in listener.incoming() {
+ // match stream {
+ // Ok(_stream) => {
+ // println!("accepted new connection");
+ // }
+ // Err(e) => {
+ // println!("error: {}", e);
+ // }
+ // }
+ // }
+}