For this Question: Given a list of positive integers, your task is to find the sum of odd and even integers separately.<b>Your task</b>
Since this is a functional problem, you don't have to worry about the input. You just have to find the sum and return it to the list.Return the list containing sum of odd and even integers respectively Sample Input:
1 3 4 5

Sample Output:
9 4

Sample Input:
2 10 11 17 18

Sample Output:
28 30, I have written this Solution Code: def posSum(list):
    res = []
    pos_even_sum = 0
    pos_odd_sum = 0
    for num in list: 
        if(num % 2 == 0):
            pos_even_sum += num 
        else: 
            pos_odd_sum += num
    
    res.append(pos_odd_sum)
    res.append(pos_even_sum)
    return res

, In this Programming Language: Python, Now tell me if this Code is compilable or not?