# 변수 : 값을 저장하는 상자

str = 'Hello'
print(str)
print(type(str))
print(len(str))

print(str * 3)
print(str + str)


'''변수 이름 규칙
1. 알파벳, 한글, 숫자, _ 로 구성
2. 숫자로 시작 금지!!
3. 파이썬 예약어(for, while, if 등) 금지!!
4. 빈칸, 연산자(+,-,*,/) 금지!!

예제
2apple
banana_3
for
my name
학생이름
age 10
total_sum
a
money+
321
'''

#자료형 사칙연산
a = 10
b = 4

print(type(a))
print(a + b)  # 더하기
print(a - b)  # 빼기
print(a * b)  # 곱하기
print(a / b)  # 나누기
print(a + 3)
#print(c + 3)

'''예제
어떤 자연수에 2를 곱하고, 10을 뺐더니 12가 나왔어
이 숫자는 뭘까? 
num1 = 12
num2 = num1 + 10
answer = num2 / 2

print(num2)
print(answer)'''


apple = 3 
banana = 5  
banana = 6
total = apple + banana  

print(total)

#문자열 변수
name = "이름"
print("안녕하세요, 저는 " + name + "입니다.")

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: