본문 바로가기

Python 🎧

[python] 파이썬 타입 힌트

파이썬 type hint 라는게 있는데,

입력값과 리턴값의 형태를 지정할 수 있도록 힌트를 준단다

 

# name 은 str ,  return 은 str
def hi(name : str) -> str :
	return 'hi' + str