Guest User

Untitled

a guest
Jan 16th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. struct AccountBalance: Decodable {
  2. let balance: Double
  3. let currency: String
  4.  
  5. init(balance: Double, currency: String ) {
  6. self.currency = currency
  7. self.balance = balance
  8. }
  9.  
  10. enum CodingKeys: String, CodingKey {
  11. case currency = "Currency"
  12. case balance = "Balance"
  13. }
  14.  
  15. let result = zip(accountBalance, getsSaved).enumerate().filter() {
  16. $1.0 == $1.1
  17. }.map{$0.0}
  18.  
  19. Closure tuple parameter '(offset: Int, element: (AccountBalance, AccountBalance))' does not support destructuring with implicit parameters
Add Comment
Please, Sign In to add comment