I don't understand my code is not working for this small question

  • 0


    I am getting this error:

    #Runtime Error Message:
    #Line 9: MemoryError ; line 9 is for i in range(a):
    #Last executed input:

    class Solution(object):
    def getSum(self, a, b):
    :type a: int
    :type b: int
    :rtype: int
    lst = []
    for i in range(a):
    for i in range(b):
    return len(lst)

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.