From 5e93c3f0240ac3e94abbdc0bc97570025b44695a Mon Sep 17 00:00:00 2001 From: Yudong Jin Date: Wed, 4 Dec 2024 17:31:46 +0800 Subject: [PATCH] Update time_complexity.rs --- codes/rust/chapter_computational_complexity/time_complexity.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codes/rust/chapter_computational_complexity/time_complexity.rs b/codes/rust/chapter_computational_complexity/time_complexity.rs index b421b3007..8fb4121a2 100644 --- a/codes/rust/chapter_computational_complexity/time_complexity.rs +++ b/codes/rust/chapter_computational_complexity/time_complexity.rs @@ -86,7 +86,7 @@ fn exp_recur(n: i32) -> i32 { if n == 1 { return 1; } - exp_recur(n - 1) + exp_recur(n - 1) + exp_recur(n - 1) + exp_recur(n - 1) + 1 } /* 对数阶(循环实现) */