added leftd(), nulld() and lbp