[꿀팁] 티스토리 구글 애드센스 승인이 안될 때 반드시 확인해야 할 것!
구글 애드센스를 달고 싶어하는 분들이 글을 몇 자 이상 써야 된다던지, 사진이 뭐 몇 개 있어야 된다던지와 같은 조건을 이야기하는데요. 사실 이러한 조건들이 출처가 애매하고 불분명합니다. 정확하게 누가 이런 말을 했는지도 알 수가 없죠. https://support.google.com/adsense/answer/9680050 에 기준이 나와 있긴 하지만(콘텐츠 불충분, 콘텐츠 품질 문제, 콘텐츠 정책 위반, 트래픽 소스의 문제가 반려 사유), 정확한 수치는 없어 개인만의 기준을 가져가게 됩니다.
위와 같이 사람마다 생각하는 기준이 있고, 그 기준에 맞춰 글을 다 썼다고 생각하면 티스토리 애드센스 승인받기 글을 읽...
[프로그래머스] 최댓값과 최솟값 풀이
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/12939
2. 풀이
map 함수를 이용하여 모두 int로 변경한 후에, 최소 최대값을 찾아서 답을 return 합니다.
def solution(s):
num_list = list(map(int, s.split()))
return "%d %d" % (min(num_list) , max(num_list))
[프로그래머스] 숫자의 표현 풀이
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/12924
2. 풀이
$ \frac{n(n+1)}{2} $ 공식을 이용하여 구간 합을 구하는 함수를 생성한 후에 모든 구간을 조사합니다.
def range_sum(a, b):
return b*(b+1)/2 - (a-1)*(a)/2
def solution(n):
answer = 0
for a in range(1, n + 1):
for b in range(a + 1, n + 1):
r_sum = range_sum(a, b)
...
[Error solve] npm install error solve _ unable to verify the first certificate
1. Problem
You can meet SSL certificate problem problem on Company or private nework place. The error is like under text.
$ npm install --global --production windows-build-tools
npm ERR! code UNABLE_TO_VERIFY_LEAF_SIGNATURE
npm ERR! errno UNABLE_TO_VERIFY_LEAF_SIGNATURE
npm ERR! request to https://registry.npmjs.org/windows-build-tools failed,...
[Error solve] git error _ SSL certificate problem
1. Problem
You can meet SSL certificate problem problem on Company or private nework place. The error is like under text.
$ git clone https://github.com/pynvme/pynvme
Cloning into 'pynvme'...
fatal: unable to access 'https://github.com/pynvme/pynvme/': SSL certificate problem: unable to get local issuer certificate
2. Solve
You can solve th...
[프로그래머스] 캐시 풀이
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/17680
2. 풀이
cash 역할을 하는 딕셔너리를 활용합니다.
딕셔너리에 있는 요소들 중에 가장 마지막에 사용한 요소를 찾아서 제거합니다.
def solution(cacheSize, cities):
if cacheSize == 0:
return len(cities)*5
cash = {}
answer = 0
cash_num = 0
for i in range(len(cities)):
if cities[i].lower() not in...
[프로그래머스] 실패율 풀이
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/42889
2. 풀이
2.1. lower_bound, upper_bound를 사용하여 해결한 풀이
먼저 배열을 정렬합니다. c++의 lower_bound, upper_bound 와 같은 함수로 bisect_left, bisect_right 함수가 존재합니다.
위의 함수들을 이용하여 찾고자 하는 숫자의 범위를 $ log(n) $ 의 효율성으로 구합니다.
최대 n 의 값에 대하여 위의 연산을 수행하기 때문에, $ n * log(\text{len(stages)}) $ 의 효율성을 가집니다.
imp...
[프로그래머스] 올바른 괄호 풀이
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/12909
2. 풀이
def solution(s):
left = 0
for i, x in enumerate(s): # 모든 글자를 확인하면서 ( 보다 ) 가 많이 나온 경우에 False return
if x == '(':
left += 1
else:
left -= 1
if left < 0:
return False
if left !=...
[프로그래머스] 다음 큰 숫자 풀이
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/12911
2. 풀이
def solution(n):
one_num = sum(list(map(int, bin(n)[2:]))) # 2진수로 변환한 뒤에 모든 숫자 더하기
while True:
n += 1
if one_num == sum(list(map(int, bin(n)[2:]))): # 1의 개수가 같으면 종료
return n
[프로그래머스] 프렌즈4블록 풀이_ 2018 KAKAO BLIND RECRUITMENT
1. 문제
https://programmers.co.kr/learn/courses/30/lessons/17679
2. 풀이
시뮬레이션을 이용하여 풀면 되는 문제입니다.
상세 풀이는 주석을 통하여 정리하였습니다.
def solution(m, n, board):
new_board = [list(x) for x in board]
delete_list = []
while True:
# 4개 일치하는 영역 찾고 배열에 넣기
for r_idx in range(m - 1):
for c_idx in range(n - 1):
...
797 post articles, 80 pages.