일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 29 | 30 | 31 |
- 파이썬
- gs25
- 맥북
- Kaggle
- dacon
- PYTHON
- hackerrank
- 데이콘
- ubuntu
- 편스토랑
- ChatGPT
- Real or Not? NLP with Disaster Tweets
- AI 경진대회
- programmers
- SW Expert Academy
- 금융문자분석경진대회
- 편스토랑 우승상품
- 백준
- 프로그래머스
- 자연어처리
- Git
- github
- 프로그래머스 파이썬
- Docker
- 캐치카페
- leetcode
- Baekjoon
- 더현대서울 맛집
- 우분투
- 코로나19
- Today
- Total
목록
반응형
전체 글 (1653)
솜씨좋은장씨
Write a function that reverses a string. The input string is given as an array of characters char[]. Do not allocate extra space for another array, you must do this by modifying the input array in-place with O(1) extra memory. You may assume all the characters consist of printable ascii characters. Example 1: Input: ["h","e","l","l","o"] Output: ["o","l","l","e","h"] Example 2: Input: ["H","a","..
Say you have an array for which the ith element is the price of a given stock on day i. If you were only permitted to complete at most one transaction (i.e., buy one and sell one share of the stock), design an algorithm to find the maximum profit. Note that you cannot sell a stock before you buy one. Example 1: Input: [7,1,5,3,6,4] Output: 5 Explanation: Buy on day 2 (price = 1) and sell on day ..
Given a string s and a string t, check if s is subsequence of t. A subsequence of a string is a new string which is formed from the original string by deleting some (can be none) of the characters without disturbing the relative positions of the remaining characters. (ie, "ace" is a subsequence of "abcde" while "aec" is not). Follow up: If there are lots of incoming S, say S1, S2, ... , Sk where..
csv로 되어있는 파일을 전달 받아 Windows에서 엑셀프로그램으로 해당 파일을 열었을때 위와 같이 파일 내의 내용이 깨져서 나오는 경우가 종종 있습니다. 원인 원인은 전달 받은 파일이 utf-8 또는 다른 형식으로 인코딩이 되어있기 때문입니다. 해결방법 해결방법은 다음과 같습니다. 먼저 전달받거나 다운로드 받은 파일을 바로 열지말고 엑셀 프로그램을 먼저 실행합니다. 메뉴에서 데이터 > 텍스트/CSV 를 선택합니다. 그러면 열리는 창에서 열어보려고 하는 csv파일을 선택합니다. 파일 원본 항목에서 65001: 유니코드(UTF-8)을 선택하고 로드를 클릭하면 위와 같이 데이터가 정상적으로 로드되어 보여지는 것을 확인할 수 있습니다. 만약 위처럼 데이터 > 텍스트/CSV 메뉴가 없는 경우에는 데이터 > 새..
We are given two arrays A and B of words. Each word is a string of lowercase letters. Now, say that word b is a subset of word a if every letter in b occurs in a, including multiplicity. For example, "wrr" is a subset of "warrior", but is not a subset of "world". Now say a word a from A is universal if for every b in B, b is a subset of a. Return a list of all universal words in A. You can retur..
You are given a string representing an attendance record for a student. The record only contains the following three characters: 'A' : Absent. 'L' : Late. 'P' : Present. A student could be rewarded if his attendance record doesn't contain more than one 'A' (absent) or more than two continuous 'L' (late). You need to return whether the student could be rewarded according to his attendance record...
Write a function that takes a string as input and reverse only the vowels of a string. Example 1: Input: "hello" Output: "holle" Example 2: Input: "leetcode" Output: "leotcede" Note: The vowels does not include the letter "y". Solution class Solution(object): def reverseVowels(self, s): s_list = list(s) vowels = [] for i, val in enumerate(s_list): if val in ['a', 'o', 'e', 'i', 'u', 'A', 'O', 'E..
Given an array of integers where 1 ≤ a[i] ≤ n (n = size of array), some elements appear twice and others appear once. Find all the elements of [1, n] inclusive that do not appear in this array. Could you do it without extra space and in O(n) runtime? You may assume the returned list does not count as extra space. Example: Input: [4,3,2,7,8,2,3,1] Output: [5,6] Solution class Solution: def findDi..