#NEWLINE# @ staticmethod #NEWLINE# @ recurrence_memo ( [ 1 , 1 ] ) #NEWLINE# def _bell( n , prev ) : #NEWLINE# #INDENT# s = 1 #NEWLINE# a = 1 #NEWLINE# for k in range ( 1 , k ) : #NEWLINE# #INDENT# a = ( ( a * ( n - k ) ) // k ) #NEWLINE# s += ( a * prev [ k ] ) #NEWLINE# #UNINDENT# return s