[Fraction to Recurring Decimal]

https://leetcode.com/problems/fraction-to-recurring-decimal/


Recurring Decimal - 순환소수

순환소수는 소수점 아래의 어떤 자리부터 일정한 숫자의 배열이 끝없이 되풀이되는 무한소수


순환소수는 무한등비급수를 이용하여 분수로 나타낼 수 있으므로, 모든 순환소수는 유리수이다.


n/q에서 정수 n을 양의 정수 q로 나누면 나머지로 가능한 수는 0부터 (q-1)뿐이므로 나누는 과정에서 나머지가 반복될 수 밖에 없다.





[Product of Array Except]

https://leetcode.com/problems/product-of-array-except-self/


변수 2개를 사용한다.

'컴퓨터공학 > Program Solving' 카테고리의 다른 글

[Leetcode] 160309  (0) 2016.03.09
[Leetcode] 160308  (0) 2016.03.08
[Leetcode] 160302  (0) 2016.03.02
[Leetcode] 160301  (0) 2016.03.02
[leetcode] 160229  (0) 2016.02.29

+ Recent posts