본문 바로가기
Programming Languages/Python

사칙연산하기

by Juunny 2026. 5. 7.

사칙연산을 시켜 출력할 수도 있다.

 

다음과 같이 입력해보자.

 

print(1 + 8)    -----> 더하기
print(10 - 2)   -----> 빼기
print(4 * 7)   -----> 곱하기
print(9 / 3)   -----> 나누기

 

 

 

출력시 다음과 같이 계산되어 출력된다.

 

LIST

'Programming Languages > Python' 카테고리의 다른 글

숫자 출력하기  (0) 2026.05.06
Hello World! 출력하기  (0) 2026.05.05
PyCharm 설치하기(Python IDE)  (0) 2023.01.15
Python의 시작  (0) 2023.01.15

댓글