전체 글236 [Compose] TextField에서 엔터키 사용하기 https://velog.io/@dddiri/TextField%EC%97%90%EC%84%9C-%EC%97%94%ED%84%B0-%ED%82%A4-%EC%82%AC%EC%9A%A9%ED%95%98%EA%B8%B0 Jetpack Compose TextField에서 엔터키 사용하기TextField의 keyboardActions, keyboardOptions 속성을 이용하여 엔터키를 자유롭게 커스텀할 수 있습니다. 물론 엔터키 외의 다른 키도 커스텀 할 수 있지만, 이번 글에서는 엔터키를 커스텀 하는 방법만 다velog.io@Composablefun InputText( ... submit: () -> Unit = {}) { val keyboardController = LocalSoftwareK.. 2024. 11. 21. [LeetCode][Kotlin] 239. Sliding Window Maximum 239. Sliding Window MaximumYou are given an array of integers nums, there is a sliding window of size k which is moving from the very left of the array to the very right. You can only see the k numbers in the window. Each time the sliding window moves right by one position. Return the max sliding window.정수 nums 배열이 주어지고, 배열의 가장 왼쪽에서 가장 오른쪽으로 이동하는 k 크기의 슬라이딩 윈도우가 있습니다. 윈도우에서 k개의 숫자만 볼 수 있습니다. 슬라이.. 2024. 11. 21. [Kotlin] 에러(Error)와 예외(Exception) https://inpa.tistory.com/entry/JAVA-%E2%98%95-%EC%97%90%EB%9F%ACError-%EC%99%80-%EC%98%88%EC%99%B8-%ED%81%B4%EB%9E%98%EC%8A%A4Exception-%F0%9F%92%AF-%EC%B4%9D%EC%A0%95%EB%A6%AC ☕ 자바 에러(Error) 와 예외 클래스(Exception) 💯 이해하기프로그래밍의 오류 종류 프로그램에서 오류가 발생하면 시스템 레벨에서 프로그램에 문제를 야기하여 원치 않는 버그를 일으키거나, 심각하면 실행 중인 프로그램을 강제로 종료시키도 한다.inpa.tistory.com에러(error) : 프로그램 코드에 의해서 수습될 수 없는 심각한 오류예외(exception) : 프로그램 코드.. 2024. 11. 20. [Data Structure][Kotlin] 해시(Hash) 해시(Hash)단방향 암호화 기법평문을 암호문으로 바꾸는 암호화는 가능하지만, 암호문을 평문으로 바꾸는 복호화는 불가능하다.입력된 값을 산술 연산을 통해 출력 데이터가 있는 위치를 식별할 수 있는 값으로 변환하는 것*해시 함수를 통해 입력 값이 데이터가 있는 곳을 알 수 있는 출력 값으로 연결될 수 있으므로, 해시 함수는 입력 값을 출력 값으로 mapping(매핑)해주는 함수라고도 한다.해시 함수 : 임의의 길이를 가진 데이터를 입력받아 고정된 길이의 값, 즉 해시값을 출력하는 함수 해시 맵(HashMap), 해시 테이블(Hash Table)해시 기법을 사용하여 데이터를 보관하는 자료구조데이터에 접근하거나 검색할 때 데이터들을 순회하면서 일일이 비교하는 일반적인 자료구조와 다르게 key 값을 통해 한 번.. 2024. 11. 19. [LeetCode][Kotlin] 76. Minimum Window Substring 76. Minimum Window SubstringGiven two strings s and t of lengths m and n respectively, return the minimum window substring of s such that every character in t (including duplicates) is included in the window. If there is no such substring, return the empty string "". The testcases will be generated such that the answer is unique.각각 길이가 m과 n인 두 개의 문자열 s와 t가 주어지면 t의 모든 문자(중복 포함)가 윈도우에 포함되도록 s의 최소 .. 2024. 11. 18. [Compose] 목록 및 그리드 목록 및 그리드 | Jetpack Compose | Android Developers이 페이지는 Cloud Translation API를 통해 번역되었습니다. 목록 및 그리드 컬렉션을 사용해 정리하기 내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요. 많은 앱에서 항목의 컬렉션을 표시해developer.android.com@Composablefun MessageList(messages: List) { Column { messages.forEach { message -> MessageRow(message) } }}스크롤이 필요하지 않은 경우 (방향에 따라) 간단한 Column 또는 Row 를 사용하여 다음과 같이 목록을 반복하여 각 항목의 콘.. 2024. 11. 17. [LeetCode][Kotlin] 2962. Count Subarrays Where Max Element Appears at Least K Times 2962. Count Subarrays Where Max Element Appears at Least K TimesYou are given an integer array nums and a positive integer k. Return the number of subarrays where the maximum element of nums appears at least k times in that subarray. A subarray is a contiguous sequence of elements within an array.정수 배열 nums와 양의 정수 k가 주어집니다. nums의 최대 요소가 해당 하위 배열에 최소 k번 나타나는 하위 배열의 개수를 반환합니다. 하위 배열은 배열 내의 연속된 요소 .. 2024. 11. 16. 이전 1 ··· 6 7 8 9 10 11 12 ··· 34 다음