일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- enumerate
- 2557
- itertools
- 파이썬
- python
- Dictionary
- Codeforces
- BOJ
- convention
- 외래키
- 큰 수 나누기
- flask
- lower_case_table_names
- 네이밍
- 에라토스테네스의 체
- datetime
- 소수
- floor
- project euler
- timestamp
- 리스트 컴프리헨션
- ceil
- FOREIGN KEY
- 세그먼트 트리
- 자료구조
- SUM()
- 딕셔너리
- SUM
- mysql
- list comprehension
- Today
- Total
목록분류 전체보기 (465)
늒네 기록
Build Your First Android App in Kotlin | Android Developers In this codelab, you’ll build your first Android app in Kotlin. You’ll learn how to use Android Studio to create an app, add UI elements known as views to your app, and add click handlers for the views. You’ll finish by adding a second screen to your developer.android.com 앞선 글에서 리소스 스트링 값을 변경하는 방법을 다뤘다면, 이번 글에서는 새로운 color 리소스를 넣고 적용하는 방..
Build Your First Android App in Kotlin | Android Developers In this codelab, you’ll build your first Android app in Kotlin. You’ll learn how to use Android Studio to create an app, add UI elements known as views to your app, and add click handlers for the views. You’ll finish by adding a second screen to your developer.android.com 이번 글에서는 위 링크의 4단계부터 이어가보도록 하겠다. 4. Task: Explore the layout edito..
Build Your First Android App in Kotlin | Android Developers In this codelab, you’ll build your first Android app in Kotlin. You’ll learn how to use Android Studio to create an app, add UI elements known as views to your app, and add click handlers for the views. You’ll finish by adding a second screen to your developer.android.com 이전 글에서는 위 링크의 1, 2번 단계를 정리해두었다. 이 글에서는 3번을 정리하도록 하겠다. 흥미로운 것을 발견했..
Build Your First Android App in Kotlin | Android Developers In this codelab, you’ll build your first Android app in Kotlin. You’ll learn how to use Android Studio to create an app, add UI elements known as views to your app, and add click handlers for the views. You’ll finish by adding a second screen to your developer.android.com 이 글 시리즈는 앱 개발을 한 번도 해보지 않은 개발자가 코틀린을 찍먹해보는 입장에서 위의 링크를 무작정 따라하면서 ..
우리에게 json_field라는, json형식의 칼럼이 들어있는 mytable이라는 테이블이 주어져있다고 하자. 예시 상황이니 다른 칼럼들을 신경쓰지 말고, 아래 sql문이 에러 없이 돌아가는 테이블이라고 치자. 1 2 3 4 5 6 7 8 9 INSERT INTO mytable (json_field) VALUES ( '{ "title": "hello", "content": "never mind", "date": "2020-11-21", "tags": ["diary", "2020-11"] }' ); cs 대강 상황을 만들어보자면, 우리는 테이블에 제목, 내용, 날짜, 태그가 들어있는, 게시글 같은 걸 저장하려 한다고 해보자. 그렇다면, 여기서 제목을 "I'm here!" 같이, 작은 따옴표가 들어가도록 ..
docs.python.org/3/howto/sorting.html Sorting HOW TO — Python 3.9.0 documentation Sorting HOW TO Author Andrew Dalke and Raymond Hettinger Release 0.1 Python lists have a built-in list.sort() method that modifies the list in-place. There is also a sorted() built-in function that builds a new sorted list from an iterable. In this documen docs.python.org 위 페이지에서 'key functions'의 내용을 정리한다. 1 2 print..
https://flask.palletsprojects.com/en/1.1.x/patterns/fileuploads/ Uploading Files — Flask Documentation (1.1.x) Uploading Files Ah yes, the good old problem of file uploads. The basic idea of file uploads is actually quite simple. It basically works like this: A tag is marked with enctype=multipart/form-data and an is placed in that form. The application accesses th flask.palletsprojects.com 해당 페..
2020/10/09 - [언어 공부 기록/python] - [python] unzip()함수는 없을까? 앞선 글에서 아래의 상황을 마주쳤다. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 a = [1, 2, 3, 4] b = ['a', 'b', 'c', 'd', 'e'] c = ['foo', 'bar', 'baz'] y = zip(a, b, c) print(y) # print(list(y)) # [(1, 'a', 'foo'), (2, 'b', 'bar'), (3, 'c', 'baz')] aa, bb, cc = zip(*y) ''' Traceback (most recent call last): File "cf.py", line 10, in aa, bb, cc = zip(*y) ..
2020/10/09 - [언어 공부 기록/python] - [python] zip() 함수에 대하여 글에서 iterable한 객체들이 주어져있고 이 객체들이 들고 있는 아이템을 순서대로 묶고싶을 때 zip() 함수를 쓰면 된다고 했다. 그렇다면, 딱 이 과정을 역방향으로 진행해주는 unzip 함수는 없을까? 예를 들어, 아래와 같은 상황이라고 하자. 1 2 3 4 5 6 7 8 9 10 a = [1, 2, 3] b = ['a', 'b', 'c'] c = ['foo', 'bar', 'baz'] y = zip(a, b, c) print(y) # print(list(y)) # [(1, 'a', 'foo'), (2, 'b', 'bar'), (3, 'c', 'baz')] aa, bb, cc = unzip(y) #..
서로 다른 두 리스트로 작업을 하다가, 둘을 같은 순서에 있는 아이템끼리 묶어서 쓸 일이 있을때 사용하는 것이 바로 zip() 함수다. 예를 들어, 아래와 같은 상황이 주어져있다고 하자. 1 2 3 4 5 6 7 8 9 a = [1, 2, 3] b = ['a', 'b', 'c'] c = ['foo', 'bar', 'baz'] x = [] for i in range(len(a)): x.append((a[i], b[i], c[i])) # x = [(1, 'a', 'foo'), (2, 'b', 'bar'), (3, 'c', 'baz')] cs 이때, 6번째 줄의 for문을 돌면서 x에 a, b, c에 들어있는 아이템을 순서대로 묶어서 넣어주었는데, 이 작업을 편하게 해주는 것이 바로 zip()함수이다. 1 2..