Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
Tags
- SSH
- Selenium
- 프로그래머스
- 핑거스타일
- Numpy
- C++
- OpenCV
- Python
- Docker
- pandas
- label
- mysql
- nvidia-smi
- Linux
- pip
- windows forms
- 컨테이너
- C
- C#
- 기타 연주
- 채보
- Visual Studio
- 오류
- pytorch
- paramiko
- error
- ubuntu
- VS Code
- YOLO
- JSON
Archives
- Today
- Total
목록base 10 (1)
기계는 거짓말하지 않는다
Python ValueError: invalid literal for int() with base 10
Python 형 변환 시 다음과 같은 오류를 볼 때가 있다. ValueError: invalid literal for int() with base 10 아래 코드는 오류를 일으킨다. str = "35.231" intVal = int(str) print(intVal) string을 int로 형 변환 시 소수점 형식일 경우 우선 float 변환 후 진행한다. str = "35.231" intVal = int(float(str)) print(intVal)
Python
2021. 8. 2. 09:58