Update 0017.电话号码的字母组合.md

更正时间复杂度说明。
This commit is contained in:
Jeff Lin 2024-04-28 15:58:38 -07:00 committed by GitHub
parent c89040cd4c
commit 2e489ea3bb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -180,7 +180,7 @@ public:
}
};
```
* 时间复杂度: O(3^m * 4^n),其中 m 是对应四个字母的数字个数n 是对应三个字母的数字个数
* 时间复杂度: O(3^m * 4^n),其中 m 是对应三个字母的数字个数n 是对应四个字母的数字个数
* 空间复杂度: O(3^m * 4^n)
一些写法,是把回溯的过程放在递归函数里了,例如如下代码,我可以写成这样:(注意注释中不一样的地方)