#6097
'''
h, w = map(int, input().split()) # w는 가로 h는 세로
n = input() # n은 막대의 개수
n = int(n)
board = [[0]*w for i in range(h)]
for i in range(n):
l, d, x, y = map(int, input().split()) # l은 막대의 길이, d는 방향(가로: 0, 세로: 1)
if d != 0:
for j in range(l):
board[x - 1+j][y - 1] = 1
else:
for j in range(l):
board[x-1][y-1+j] = 1
for i in range(h):
for j in range(w):
print(board[i][j], end=' ')
print()
'''
#6098
# # 0: 길, 1: 벽, 2: 먹이
# board = [[int(x) for x in input().split()]for y in range(10)]
'''
house = [[0]*10 for _ in range(10)]
for i in range(10):
house[i] = list(map(int, input().split()))
'''
# for in range() :
#
# class Maze:
#
# def __init__(self):
# self.x=0
# self.y=0
#
#
# def func_c(self):
# self.board = [[int(x) for 9 in input().split()]for y in range(9)]
# return self.board
# def func_b(self):
# self.x =1
# self.y=1
# while True :
# if self.board[self.x][self.y + 1] == 0:
# self.board[self.x][self.y + 1] = 9
# return self.board
#
# elif self.board[self.x][self.y + 1] == 2:
# self.board[self.x][self.y + 1]=9
# break
#
# elif self.board[self.x+1][self.y]==2:
# self.board[self.x + 1][self.y]=9
# break
# else:
# self.board[self.x + 1][self.y]
# return self.board
#
# m1= Maze(board)
# print(m1.func_b())
class search:
def __init__(self, map, x, y):
self.map = map
self.x = x
self.y = y
def process(self):
######
while True:
if self.map[self.x][self.y] == 2:
self.map[self.x][self.y] = 9
break
else:
if self.map[self.x][self.y + 1] == 0:
self.map[self.x][self.y + 1] =0
self.map[self.x][self.y + 1] = 9
self.y=self.y + 1
elif self.map[self.x][self.y + 1] == 1:
if self.x+1<<10:
self.map[self.x + 1][self.y] = 9
self.x = self.x + 1
for i in range(len(self.map)):
for j in range(len(self.map[i])):
print(map[i][j], end=' ')
print()
map = []
for i in range(10):
v = input().split()
for j in range(len(v)):
v[j] = int(v[j])
map.append(v)
playing = search(map, 1, 1)
playing.process()
'''
#클래스 설명
class academy:
def __init__(self):
self.a = 100
print('HELLO')
self.variable()
def variable(self):
self.a = 200
self.vv = 2000
print('WORLD')
x = academy()
x.variable()
data = []
for i in range(5):
p = academy()
data.append(p)
data[0].variable()
'''
top of page
기능을 테스트하려면 라이브 사이트로 이동하세요.
220115
220115
댓글 0개
좋아요
댓글(0)
bottom of page