<body ng-app >
<div ng-init="cartdetail= ['1', '2', '3']">
{{cartdetail}}
<ul><li ng-repeat="num in cartdetail">
<input ng-model="cartdetail[$index]"></input>
</li>
</ul>
</div>
</body>
<li ng-repeat="(j, value) in cartdetail track by $index">
<input ng-model="cartdetail[j]"></input>
</li>
<body ng-app >
<div ng-init="cartdetail= [{qty:'1'},{qty: '2'},{qty: '3'}]">
{{cartdetail}}
<ul><li ng-repeat="obj in cartdetail">
<input ng-model="obj.qty"></input>
</li>
</ul>
</div>
</body>