From 2bf963a2ef4e85ed24a527af18fe19cf55e9863f Mon Sep 17 00:00:00 2001 From: ivan Date: Sat, 15 Aug 2026 04:57:53 -0600 Subject: [PATCH] adding updates --- .../round_7/the_kth_factor.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/my_project/interviews/amazon_high_frequency_23/round_7/the_kth_factor.py diff --git a/src/my_project/interviews/amazon_high_frequency_23/round_7/the_kth_factor.py b/src/my_project/interviews/amazon_high_frequency_23/round_7/the_kth_factor.py new file mode 100644 index 00000000..a0e8dc24 --- /dev/null +++ b/src/my_project/interviews/amazon_high_frequency_23/round_7/the_kth_factor.py @@ -0,0 +1,17 @@ +class Solution: + def kthFactor(self, n, k): + """ + :type n: int + :type k: int + :rtype: int + """ + + for i in range(1, n+1): + + if n % i == 0: + k -= 1 + + if k == 0: + return i + + return -1 \ No newline at end of file