#NEWLINE# def add( self , l , st , ptr ) : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# ctr = st [ id ( self ) ] #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# ctr = st [ id ( self ) ] = 0 #NEWLINE# #UNINDENT# if ( ( ctr >= self . a ) and ( ( self . b is None ) or ( ctr <= self . b ) ) ) : #NEWLINE# #INDENT# st2 = st . copy ( ) #NEWLINE# count = st2 . pop ( id ( self ) ) #NEWLINE# try : #NEWLINE# #INDENT# st2 [ self . name ] = ( st2 [ self . name ] + ( count , ) ) #NEWLINE# #UNINDENT# except KeyError : #NEWLINE# #INDENT# st2 [ self . name ] = ( count , ) #NEWLINE# #UNINDENT# self . out . add ( l , st2 , ptr ) #NEWLINE# #UNINDENT# ctr += 1 #NEWLINE# st [ id ( st2 ) ] = ctr #NEWLINE# if ( ( self . b is None ) or ( ctr <= self . b ) ) : #NEWLINE# #INDENT# self . out2 . add ( l , st , ptr )