warning: initialization order
warning: signed / unsigned comparison