<reponame>seryeongi/learn_algorithm<filename>Code07-01.py
SIZE = 5
queue = [None for _ in range(SIZE)]
front, rear = -1, -1

rear += 1
queue[rear] = '화사'
rear += 1
queue[rear] = '솔라'
rear += 1
queue[rear] = '문별'
print('출구<--',queue,'<--입구')

front += 1
data = queue[front]
queue[front] = None
print('추출-->',data)
front += 1
data = queue[front]
queue[front] = None
print('추출-->',data)
front += 1
data = queue[front]
queue[front] = None
print('추출-->',data)
print('출구<--',queue,'<--입구')

SIZE = 5
queue = [None for _ in range(SIZE)]
front, rear = -1, -1

rear += 1
queue[rear] = '화사'
rear += 1
queue[rear] = '솔라'
rear += 1
queue[rear] = '문별'
print('출구<--',queue,'<--입구')

front += 1
data = queue[front]
queue[front] = None
print('추출-->',data)
front += 1
data = queue[front]
queue[front] = None
print('추출-->',data)
front += 1
data = queue[front]
queue[front] = None
print('추출-->',data)
print('출구<--',queue,'<--입구')