Displayed below is an HTML Code that includes a table which retrieves items from costList and presents them in separate rows. The objective is to exhibit the item value when a row is clicked. How can this be achieved using Angular? Your help is greatly appreciated.
<table>
<tr ng-click = "displayItem()" ng-repeat = "item in costList">
<td>{{item}}</td>
</tr>
</table>