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 |
Tags
- permutations
- Python 몫
- 프로그래머스
- sting position
- string
- 알고리즘
- sort()
- Python
- List 초기화
- Split
- homebrew-core is a shallow clone.
- list to set
- zip()
- index
- COUNT
- list.pop(0)
- list.sorted()
- List
- Boto3
- 피보나치 수
- python3
- cask
- Algorithm
- Unknown command: cask
- set to list
- Modified Date
- 알고리즘 풀이
- RecursionError
- List to String
- Python 나머지
Archives
- Today
- Total
데이터와 코드로 세상을 바라봅니다.
[Python3] - String, index, concat, add 본문
def solution(N):
answer = ''
for i in range(1,N+1):
answer_star = ''
for k in range(1,i+1):
answer_star = answer_star+"*"
answer = answer+answer_star+"\n"
answer = answer[:-1]
print(answer)
return answer
[문제] - 별 찍기 - 1
문제 설명
첫번째 줄에서 N번째 줄까지 다음과 같은 규칙으로 출력한 결과값을 구하여라.
(1 <= N <= 100)
N = 1
*
N = 3
*
**
***
N = 4
*
**
***
****
[참고자료]
위키독스
온라인 책을 제작 공유하는 플랫폼 서비스
wikidocs.net
[python] 문자열을 효율적으로 concat 하는 방법
파이썬에서 문자열을 효율적으로 concat 하는 방법을 찾아보다가 좋은 사이트를 발견해서 스크랩 해본다. 원문에서 방법 4, 5, 6을 추천하고 있다. 방법 6이 가장 빠르기 때문에 많이 사용하고, 방
118k.tistory.com
'Code > Python' 카테고리의 다른 글
[Python3] - for, string add (0) | 2020.11.23 |
---|---|
[Python3] - String reverse, String split (0) | 2020.11.18 |
[Python 3] - list(), stack concept, pop(), len(), append() (0) | 2020.11.09 |
[Python 3] - List, sorted(), pop(), index() (0) | 2020.11.06 |
[Python 3] - String, Upper(), Lower(), Count(), Contain() (0) | 2020.11.05 |