mirror of
https://github.com/ShusenTang/LeetCode.git
synced 2024-09-02 14:20:01 +00:00
Update 166. Fraction to Recurring Decimal.md
This commit is contained in:
parent
41c41111b3
commit
4e37967b03
@ -13,6 +13,9 @@
|
||||
|
||||
考虑无限循环小数该怎么办呢? 前面说到, 在循环里r是会不断更新的, 所以我们需记录每次循环r的值, 这样当r重复时, 就可以将两次循环之间得到的结果用括号括起来.
|
||||
|
||||
**注意整数转字符串可以很方便地用to_string(), 另外insert对字符串进行插入.**
|
||||
|
||||
|
||||
# C++
|
||||
``` C++
|
||||
class Solution {
|
||||
|
Loading…
Reference in New Issue
Block a user