Created
January 26, 2020 14:05
-
-
Save hongdonghyun/60fb1e38f4daf7690c830a29e7ed0320 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import math | |
# x 이상의 수 중에서 가장 작은 정수는 어는 부분의 설명인가요? 소수점 왼편 정수 부분인가요? | |
# >>> x 이상의 수중에서 가장 작은 정수 | |
# >>> 여기서 X는 저희가 입력한 값입니다. | |
# >>> x <= 가장 작은 정수 [ x(5.1) 보다 큰 정수중에서 5.1보다 큰 정수는 6,7,8,9 ] 등등이 있겠죠? | |
# >>> 그중에서 가장 작은 정수는 6이므로 6이 반환됩니다. | |
print(math.ceil.__doc__) # 해당 메서드의 설명을 볼 수 있습니다. | |
print(math.ceil(5.1)) # X는 5.1이 되겠네요. | |
print() | |
# x 이하의 수중에서 가장 큰 정수는 소수점 이하중 가장 큰 수인가요? | |
# >>> x 이하의 수중에서 가장 큰 정수 | |
# >>> 여기서 X는 저희가 입력한 값입니다. | |
# >>> 가장 큰 정수 <= x [ x(3.574)보다 작은 정수는 -1,0,1,2,3 ] 등등이 있습니다 | |
# >>> 그중에서 가장 큰 정수는 3이므로 3이 반환됩니다. | |
print(math.floor.__doc__) | |
print(math.floor(3.574)) # x 이하의 수 중에서 가장 큰 정수, 결과: 3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment