code: def ShowUnspentCoins(wallet, asset_id=None, from_addr=None, watch_only=False, do_count=False):
      
  
      if wallet is None:
          print("Please open a wallet.")
          return
  
      watch_only_flag = 64 if watch_only else 0
      if asset_id:
          unspents = wallet.FindUnspentCoinsByAsset(asset_id, from_addr=from_addr, watch_only_val=watch_only_flag)
      else:
          unspents = wallet.FindUnspentCoins(from_addr=from_addr, watch_only_val=watch_only)
  
      if do_count:
          print('\n-----------------------------------------------')
          print('Total Unspent: %s' % len(unspents))
          return unspents
  
      for unspent in unspents:
          print('\n-----------------------------------------------')
          print(json.dumps(unspent.ToJson(), indent=4))
  
      if not unspents:
          print("No unspent assets matching the arguments.")
  
      return unspents
docs: Show unspent coin objects in the wallet.
  
      Args:
          wallet (neo.Wallet): wallet to show unspent coins from.
          asset_id (UInt256): a bytearray (len 32) representing an asset on the blockchain.
          from_addr (UInt160): a bytearray (len 20) representing an address.
          watch_only (bool): indicate if this shows coins that are in 'watch only' addresses.
          do_count (bool): if True only show a count of unspent assets.
  
      Returns:
          list: a list of unspent ``neo.Wallet.Coin`` in the wallet