![](http://i1.daumcdn.net/thumb/C148x148.fwebp.q85/?fname=https://blog.kakaocdn.net/dn/cxSTaF/btrQbrzezkW/Ub8kkkK2gYtk6tXv2LcUc0/img.png)
이전 챕터와 비슷하게 filtering 연산자에 대해 공부해 보려 합니다. Filtering basics filter() Swift에 있는 filter와 같습니다. (조건문과 성립하는것만 걸러냄) var subscriptions = Set() example(of: "filter") { // 1. 1~10까지 이벤트 방출 let numbers = (1...10).publisher // 2. filter 연산자로, 3의 배수만 걸러냄 numbers .filter { $0.isMultiple(of: 3) } // isMultiple of의 지정된 숫자의 배수이면 true 반환 .sink(receiveValue: { num in print("\(num) 은 3의 배수") }) .store(in: &subscri..
iOS
2022. 11. 3. 00:07
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
TAG
- Swift RIBs
- removeLast()
- swift property
- swift (programmers)
- RTCCameraVideoCapturer
- swift 고차함수
- swift protocol
- 2023년 회고
- Swift 프로퍼티
- Swift joined
- Swift Leetcode
- iOS error
- Swift 프로그래머스
- swift reduce
- 원티드 프리온보딩
- Swift joined()
- Combine: Asynchronous Programming with Swift
- Class
- RIBs tutorial
- Swift ModernRIBs
- Swift inout
- Swift 내림차순
- Swift init
- Swift Error Handling
- Swift
- swift programmers
- CS 네트워크
- Swift final
- ios
- Swift 알고리즘
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
글 보관함