-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
Description
SORTGAME self review 
1. 해결 시도 과정
크기 비교를 위해 대소관계를 기준으로 일반화 하는 과정을 마쳤습니다.
2. 작성한 코드와 설명
def genralize(sortgame):
l=len(sortgame)
for i in range(N):
smaller=0
for j in range(N):
if sortgame[j]<sortgame[i]:
samller+=1
fixed[i]=smaller
return ''.join(str(i) for i in arr)
3. 막힌 점 및 개선 사항
bfs부분이 막혔습니다. 현재까지 진행한 상태는 다음과 같습니다.
def bfs(start,length):
queue=deque()
queue.append((start,0))
while queue:
now,level=queue.popleft()
for i in range(len(now)):
for j in range(i+1,len(now)):
now[i:j+1]=now[i:j+1][::-1]
string=''.join(now)