add Rust hello world!
This commit is contained in:
Generated
+7
@@ -0,0 +1,7 @@
|
||||
# This file is automatically @generated by Cargo.
|
||||
# It is not intended for manual editing.
|
||||
version = 4
|
||||
|
||||
[[package]]
|
||||
name = "hello_world"
|
||||
version = "0.1.0"
|
||||
@@ -0,0 +1,8 @@
|
||||
[package]
|
||||
name = "hello_world"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[[bin]]
|
||||
name = "hello_world"
|
||||
path = "src/main.rs"
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
// Rust Hello World 示範程式
|
||||
// 編譯並執行:cargo run
|
||||
|
||||
fn main() {
|
||||
// println! 是 Rust 的巨集(macro),用來印出字串並換行
|
||||
println!("Hello, World!");
|
||||
println!("你好,世界!");
|
||||
|
||||
// 變數宣告(預設為不可變)
|
||||
let name = "Rust";
|
||||
println!("歡迎使用 {} 程式語言!", name);
|
||||
|
||||
// 呼叫自訂函式
|
||||
greet("開發者");
|
||||
}
|
||||
|
||||
/// 一個簡單的問候函式
|
||||
fn greet(who: &str) {
|
||||
println!("Hi, {}! 這是一個 Rust 範例。", who);
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{"rustc_fingerprint":477736733871148030,"outputs":{"7971740275564407648":{"success":true,"status":"","code":0,"stdout":"___.exe\nlib___.rlib\n___.dll\n___.dll\nlib___.a\n___.dll\nC:\\Users\\alan\\.rustup\\toolchains\\stable-x86_64-pc-windows-gnu\noff\n___\ndebug_assertions\npanic=\"unwind\"\nproc_macro\ntarget_abi=\"\"\ntarget_arch=\"x86_64\"\ntarget_endian=\"little\"\ntarget_env=\"gnu\"\ntarget_family=\"windows\"\ntarget_feature=\"cmpxchg16b\"\ntarget_feature=\"fxsr\"\ntarget_feature=\"sse\"\ntarget_feature=\"sse2\"\ntarget_feature=\"sse3\"\ntarget_has_atomic=\"128\"\ntarget_has_atomic=\"16\"\ntarget_has_atomic=\"32\"\ntarget_has_atomic=\"64\"\ntarget_has_atomic=\"8\"\ntarget_has_atomic=\"ptr\"\ntarget_os=\"windows\"\ntarget_pointer_width=\"64\"\ntarget_vendor=\"pc\"\nwindows\n","stderr":""},"17747080675513052775":{"success":true,"status":"","code":0,"stdout":"rustc 1.94.0 (4a4ef493e 2026-03-02)\nbinary: rustc\ncommit-hash: 4a4ef493e3a1488c6e321570238084b38948f6db\ncommit-date: 2026-03-02\nhost: x86_64-pc-windows-gnu\nrelease: 1.94.0\nLLVM version: 21.1.8\n","stderr":""}},"successes":{}}
|
||||
@@ -0,0 +1,3 @@
|
||||
Signature: 8a477f597d28d172789f06886806bc55
|
||||
# This file is a cache directory tag created by cargo.
|
||||
# For information about cache directory tags see https://bford.info/cachedir/
|
||||
@@ -0,0 +1 @@
|
||||
288379d2cbea7723
|
||||
@@ -0,0 +1 @@
|
||||
{"rustc":13073507457223000659,"features":"[]","declared_features":"[]","target":10933677794921727520,"profile":8731458305071235362,"path":4942398508502643691,"deps":[],"local":[{"CheckDepInfo":{"dep_info":"debug\\.fingerprint\\hello_world-10a543a465de4575\\dep-bin-hello_world","checksum":false}}],"rustflags":[],"config":8247474407144887393,"compile_kind":0}
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
This file has an mtime of when this was started.
|
||||
@@ -0,0 +1 @@
|
||||
abfb746d06de7608
|
||||
@@ -0,0 +1 @@
|
||||
{"rustc":13073507457223000659,"features":"[]","declared_features":"[]","target":10933677794921727520,"profile":17672942494452627365,"path":4942398508502643691,"deps":[],"local":[{"CheckDepInfo":{"dep_info":"debug\\.fingerprint\\hello_world-28821d0d93adece6\\dep-bin-hello_world","checksum":false}}],"rustflags":[],"config":8247474407144887393,"compile_kind":0}
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
This file has an mtime of when this was started.
|
||||
@@ -0,0 +1,5 @@
|
||||
D:\@dev_HuKui\helloWorld\target\debug\deps\hello_world-10a543a465de4575.d: src\main.rs
|
||||
|
||||
D:\@dev_HuKui\helloWorld\target\debug\deps\hello_world-10a543a465de4575.exe: src\main.rs
|
||||
|
||||
src\main.rs:
|
||||
Binary file not shown.
@@ -0,0 +1,5 @@
|
||||
D:\@dev_HuKui\helloWorld\target\debug\deps\hello_world-28821d0d93adece6.d: src\main.rs
|
||||
|
||||
D:\@dev_HuKui\helloWorld\target\debug\deps\libhello_world-28821d0d93adece6.rmeta: src\main.rs
|
||||
|
||||
src\main.rs:
|
||||
@@ -0,0 +1 @@
|
||||
D:\@dev_HuKui\helloWorld\target\debug\hello_world.exe: D:\@dev_HuKui\helloWorld\src\main.rs
|
||||
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Reference in New Issue
Block a user