Why array pointer is returning wrong values

use "new" and "delete" operators on pointer