일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- 장고 가상환경
- 넥스트js
- 파이썬 클래스
- Variable declaration
- github
- NextJs
- 좋은글
- 강제 타입변환
- 파이썬 제어문
- Kotlin Class
- 파이썬 반복문
- Kotlin 클래스
- 클래스 속성
- Python Class
- 성공
- Kotlin else if
- 도전
- 희망
- python Django
- 파이썬
- Kotlin 클래스 속성정의
- activate 오류
- 파이썬 장고
- git
- 다중조건문
- 자바 기본타입
- Kotlin 조건문
- django virtualenv
- Kotlin If
- Python
Archives
- Today
- Total
목록파이썬 endswith (1)
키모스토리

endswith() endswith()를 이용하여 문자열이 특정 문자열로 끝이 나는지 확인할 수 있습니다. 1. endswith()로 문자열이 특정 문자열로 끝나는지 확인 예를 들어 다음과 같이 'Hello world, Python'가 Python 으로 끝나는지 확인할 수 있습니다. str = 'Hello world, Python' if str.endswith('Python'): print('It ends with Python') if not str.endswith('Hello'): print('It does not ends with Hello') Output: It ends with Python It does not end with Hello 만약 대소문자를 구분하지 않고 비교를 하고 싶다면 lower..
Python/Python
2022. 12. 15. 12:32