본문 바로가기
<Dart> Streams 비동기 프로그래밍 결론 The dart:async library contains two types that are important for many Dart APIs: Stream and Future. Where a Future represents the result of a single computation, a stream is a sequence of results. Future은 단일 계산의 결과에 대한 사용, stream은 연속된 결과를 위해 사용됩니다!!! 네, 이번 시간에는 비동기 프로그래밍인 Strams에 대해서 알아보도록 하겠습니다. 사실 Stram은 저번에 포스팅 했던 Future과 비슷한 개념이라고 생각하시면 좋을 거 같아요. 이번 포스팅도 역시 Dart 공식 문서에 나온 내용을 바탕으로 쓰여졌습니다... 2023. 3. 16.
<Dart> Effective Dart: Documentation 이번 시간에는 Efective Dart: Documentation에 대해서 공부해보도록 하겠습니다. 어떻게 하면 효과적으로 Dart를 사용할 수 있을까요? https://dart.dev/guides/language/effective-dart/documentation Effective Dart: Documentation Clear, helpful comments and documentation. dart.dev 본 포스트는 공식 문서의 내용을 중심으로 필자의 해석이 주를 이루고 있습니다! 글을 작성할때마다 무언가 어투가 바뀌는 거 같아요. 제가 정신이 없는 점 양해부탁드리면서 시작하도록 하겠습니다. 위 링크를 타고 들어가시면 가장 먼저 It’s easy to think your code is obvious.. 2023. 3. 6.
<Dart> What is Future and how to use it? Future is Dart grammer. yes maybe... The reason I choose thiis, it's kind of hard to understand and use. So through this poster, I'm gonna study it deeply. There are two references. https://dart.dev/codelabs/async-await Asynchronous programming: futures, async, await Learn about and practice writing asynchronous code in DartPad! dart.dev https://velog.io/@jintak0401/FlutterDart-%EC%97%90%EC%84%9.. 2023. 3. 2.
<자료구조와 알고리즘> 정렬 with Python Python 리스트의 정렬 함수 1) sorted() - 내장 함수 - 정렬된 새로운 리스트를 얻어낸다 2) sort() - 리스트의 메서드 - 해당 리스트를 정렬한다 사용 방법 L = [3,6,21,5] L.sort() L2 = sorted(L) 매개변수로 reverse = True를 주면 반대로 정렬된다 문자열로 정리를 하려면 어떻게 해야할까? L = ['abcd', 'xyz', 'spam'] sorted(L, key=lambda x:len(x)) 여기서 lambda는 파이썬의 익명함수 문법입니다 lambda 매개변수 : 표현식 형태로 표현합니다 그래서 key 에 x의 길이많큼 주는 것입니다 또 다른 예시로 L = [{'name' : 'John', 'score':83}, {'name':'Paul','.. 2023. 2. 20.