Actions
예외처리¶
소스코드¶
import pybithumb
import time
while True:
price = pybithumb.get_current_price("BTC") # 비트코인 현재가격 조회
# 예외처리
try:
print(price/10)
except:
print("에러발생", price)
time.sleep(0.2)import pybithumb
import time
while True:
price = pybithumb.get_current_price("BTC") # 비트코인 현재가격 조회
# 예외처리
try:
print(price/10)
except:
print("에러발생", price)
time.sleep(0.2)
결과¶
15389600.0 15389600.0 15389500.0 15389500.0 15389500.0 15389500.0 15389500.0 15389500.0 15389500.0 15389500.0 15389500.0 15389500.0
이태훈이(가) 10달 전에 변경 · 1 revisions