Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- Glue의 두 가지 핵심 기능
- 코딩테스트
- 데이터카탈로그
- 공백트림
- import from 차이점
- 맞출수있었는데...
- python
- docker airflow
- 프로그래머스
- s3목록
- 1000개 이상
- docker
- GCP mysql
- 코테
- Binary_gap
- 이직 3개월차
- 파이서닉
- Codility
- 파이써닉
- docker-compose
- 공백null치환
- cyclerotation
- 답안지표기잘못한느낌...
- 공백Trim
- 디비설치
- 차이
- AWS
- airflow설치
- Glue
- 도커 에어플로
Archives
- Today
- Total
작은하마
[Codility] odd occurrences in array 본문
https://app.codility.com/programmers/lessons/2-arrays/odd_occurrences_in_array/start/
Codility
Your browser is not supported You should use a supported browser. Read more
app.codility.com
배열 A가 주어졌을때 짝이 맞지 않는 수를 반환하는 문제이다.
배열에서 하나의 숫자 빼고는 다 짝이 맞도록 설정이되어있다.
st=list(set(a))
for i in st:
cnt=a.count(i)
if cnt==1:
answer=i
answer
처음에 이런식으로 접근을 하였는데
55점이 나왔다.
이유는 O(n**2) 시간복잡도가 만족하지 않은것...
'코딩테스트 > Codility' 카테고리의 다른 글
[Codility] 짝지어 제거하기 (0) | 2021.07.26 |
---|---|
[codility] FrogJmp (0) | 2021.07.23 |
[codility]디버깅문제 (0) | 2021.07.22 |
[codility] 합이 같은 수 (0) | 2021.07.22 |
[Codility] CyclicRotation (0) | 2021.07.21 |
Comments