add rectangle methods; added testcase
added rectangle data structure helper