adding MiddleCode problem