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
- 가상메모리
- 재귀
- DP
- MYSQL
- BOJ
- 브루트포스
- level3
- 운영체제
- 프로그래머스
- 다익스트라
- 구현
- dict
- 가상메모리 관리
- python
- level1
- 다이나믹 프로그래밍
- 파이썬
- 수학
- level2
- dfs
- BFS
- 백준
- 힙
- 코딩테스트
- 딕셔너리
- 그리디
- N과M
- level0
- programmers
- 스택
Archives
- Today
- Total
목록5525 (1)
동캄의 코딩도장
백준 5525 [IOIOI] 파이썬
https://www.acmicpc.net/problem/5525 5525번: IOIOI N+1개의 I와 N개의 O로 이루어져 있으면, I와 O이 교대로 나오는 문자열을 PN이라고 한다. P1 IOI P2 IOIOI P3 IOIOIOI PN IOIOI...OI (O가 N개) I와 O로만 이루어진 문자열 S와 정수 N이 주어졌을 때, S안에 PN이 몇 www.acmicpc.net #백준 5525 IOIOI import sys input=sys.stdin.readline N=int(input()) M=int(input()) S=list(map(str,input().rstrip())) target=2*N+1 dp=[0]*(M) answer=0 if S[0]=='I': dp[0]=1 for i in range(..
코테/BOJ
2023. 3. 21. 10:30