전체 글
![](https://tistory1.daumcdn.net/tistory/5365537/skin/images/no-image.jpg)
문제 풀이Stack 개념과 동일하다.스택(Stack)은 마지막으로 입력 데이터가 먼저 출력되는 방식이다.(LIFO : Last in First out)func stack() -> Bool { let word = readLine()! var stack: [Character] = [] word.forEach { if !stack.isEmpty && stack.last! == $0 { // 마지막 데이터 제거 stack.removeLast() } // 데이터 추가 stack.append($0) } return Set(stack).count == stack.count}let n = Int(readLi..
![](http://i1.daumcdn.net/thumb/C400x400/?fname=https://blog.kakaocdn.net/dn/bEZnoe/btsL1rrEEx9/eB9lHZ1AqwvdwauSEDEoz0/img.png)
![](https://tistory1.daumcdn.net/tistory/5365537/skin/images/no-image.jpg)
UIResponder이벤트에 응답하고 처리하기 위한 추상적인 인터페이스 Class UIResponder는 UIKit의 핵심 클래스로, 사용자 이벤트(터치, 모션, 리모트 컨트롤 등) 처리하는 객체들의 Base ClassUIView, UIViewController, UIApplication 등 대부분의 UI 컴포넌트가 UIResponder를 상속 받음Responder Chain을 통해 이벤트가 전파되는 구조를 관리 이벤트 처리UIResponder에서는 4가지 유형의 이벤트를 처리할 수 있습니다.Touchoverride func touchesBegan(_ touches: Set, with event: UIEvent?) { // 터치 시작 시 동작}Motionoverride func motionEnde..
![](http://i1.daumcdn.net/thumb/C400x400/?fname=https://blog.kakaocdn.net/dn/5rWyr/btsL3nnfFxh/7QHp0SXvU1CZ5gdr01sP4K/img.png)
![](https://tistory1.daumcdn.net/tistory/5365537/skin/images/no-image.jpg)
struct PlayerView: View{ @State private var isPlaying: Bool = false var body: some View{ PlayButton(isPlaying: $isPlaying) }}struct PlayButton: View{ @Binding var isPlaying: Bool var body: some View{ Button(action:{ self.isPlaying.toggle() }){ Image(systemName:isPlaying ? "pause.circle" : "play.circle") } }}사용자 인터페이스(UI) 상태 관리앱의 View 계층 구조..
![](https://tistory1.daumcdn.net/tistory/5365537/skin/images/no-image.jpg)
fastlane 실행 중에 아래와 같은 에러가 발생하였다. Error: Unable to upload archive. Failed to get authorization for username and password 아무리 봐도 Appstore Connect 오류인 것 같은데 정확하게 설정은 해줬다고 생각했는데 앱 암호로 설정해줘야한다. 1. 아래 사이트로 접속 Apple AccountYour account you use for all Apple servicesaccount.apple.com 2. 앱 암호 생성 생성 하면 XXXX-XXXX-XXXX-XXXX 이런 식으로 생성될 것이다.(나 같은 경우는 저런 형태였다) 3. fastlane/Appfile 또는 Fastfile에 추가ENV["FASTLANE_P..
![](https://tistory1.daumcdn.net/tistory/5365537/skin/images/no-image.jpg)
1. fastlane 설정fastlane init2. "fastlane를 무엇에 사용하고 싶으신가요?" → 3번 App Store 배포 선택3. 애플 계정 입력4. 앱의 Metadata를 fastlane으로 관리할 건가요? 기본 설정은 완료!이제 내가 배포를 하고 싶다면bundle exec fastlane ios release 완료출처 [iOS] Fastlane으로 배포 자동화하기Bundler 와 Gemfile 을 이용해서 fastlane 의존성 관리하기1-1. 터미널에서 gem install bundler 입력해서 번들러 설치만약, 에러가 발생했다면 아래 절차를 따른다.brew updatebrew install rbenv ruby-buildvelog.io Archive -> Xcode Upload..
![](http://i1.daumcdn.net/thumb/C400x400/?fname=https://blog.kakaocdn.net/dn/sbEAs/btsLJA3aaCm/cmbsfNKnRPqo2KNxmWH47K/img.png)
![](https://tistory1.daumcdn.net/tistory/5365537/skin/images/no-image.jpg)
영상Swift에서 비동기(async)로 작업하는 경우 completion을 통해서 값을 가져오고 이 값을 사용할 때마다 계속 함수를 호출해야 했음// 함수 선언func downloadJson(_ url: String, completion: @escaping ((String?) -> Void)){ let url = URL(string: url)! DispatchQueue.global().async{ let data = try! Data(contentsOf: url) let json = String(data: data, encoding: .utf8) completion(json) }}// 사용downloadJson(MY_URL){ json in le..