About 61 results
Open links in new tab
  1. Python Logic of ListNode in Leetcode - Stack Overflow

    Python Logic of ListNode in Leetcode Asked 6 years, 8 months ago Modified 4 years, 7 months ago Viewed 116k times

  2. python - LeetCode 2. Add Two Numbers - Code Review Stack Exchange

    Dec 12, 2025 · LeetCode's data structures LeetCode's linked list data structure is dumb. It doesn't do nice things like let you iterate over it using built-in functionality in Python. But you don't have to live …

  3. python - LeetCode - 2. Add Two Numbers - Stack Overflow

    Dec 13, 2023 · I'm attempting to address Leetcode problem 2. Add Two Numbers: You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order, …

  4. python - How do I properly input my own test cases in my own IDE for ...

    How do I properly input my own test cases in my own IDE for problems in leetcode.com? Asked 5 years, 7 months ago Modified 2 years, 1 month ago Viewed 8k times

  5. how does python functions inside 'Class Solution' get called ...

    May 12, 2024 · in leetcode python problems, we have the following structure-- Class Solution: def function(): {some code here} i completed the function of the specific problem but i didn't call the func...

  6. How can i improve my python code of leetcode problem 345 and how …

    Mar 9, 2025 · How can i improve my python code of leetcode problem 345 and how i can i improve the time complexity [closed] Asked 9 months ago Modified 9 months ago Viewed 149 times

  7. python - Why does this greedy algorithm work for "Lexicographically ...

    Mar 26, 2025 · I am looking at solutions to the LeetCode problem 3474. Lexicographically Smallest Generated String: You are given two strings, str1 and str2, of lengths n and m, respectively. A string …

  8. python - Leetcode 3sum problem solution - Code Review Stack Exchange

    Mar 3, 2024 · 2 I'm surprised no one on Leetcode mentioned: Assuming you are working with integers within a fixed range [-N,N], CLRS gives a O (n + N log N) solution for 3SUM. Represent nums as a …

  9. python - How to tackle time limit exceeded error in leetcode - Stack ...

    Sep 14, 2019 · How to tackle time limit exceeded error in leetcode Asked 6 years, 5 months ago Modified 1 year, 4 months ago Viewed 38k times

  10. python - NameError is not defined in leetcode problem - Stack Overflow

    Sep 14, 2021 · Please bear with me, I'm still getting used to OOP in python. I'm preparing for coding interviews, and find that Leetcode problems generally have the following structure. class Solution: def