My Python solution......,. ,., ., .,


#1
class Solution:
# @param A : list of strings
# @return an integer
def evalRPN(self, A):
    l = []
    for i in range(len(A)):
        try:
            A[i] = int(A[i])
        except:
            pass
        if (isinstance(A[i],int)):
            l.append(A[i])
        else:#+, -, *, /
            p = l.pop()
            q = l.pop()
            if A[i]=='+':
                l.append(q + p)
            if A[i]=='-':
                l.append(q - p)
            if A[i]=='*':
                l.append(q * p)
            if A[i]=='/':
                l.append(q//p)
    return l[0]