```
class Solution(object):
def integerBreak(self, n):
"""
:type n: int
:rtype: int
"""
g = 0
if n == 2:
g = 1
if n == 3:
g = 2
if n>3 and n%3 == 0:
g = 3**(n/3)
if n>3 and n%3 != 0:
for i in range(n):
if (n-2*i)%3 == 0:
g = (2**i)*(3**((n-2*i)/3))
break
else:
continue
return g
```