• 내용으로 건너뛰기

GINS WIKI 긴스 위키

사용자 도구

  • 로그인

사이트 도구

  • 최근 바뀜
  • 미디어 관리자
  • 사이트맵
현재 위치: 긴스위키 GINS wiki » format
추적:

format

검색

아래에서 검색 결과를 찾을 수 있습니다.

끝
  • 정확히 일치
  • 시작
  • 끝
  • Contains
@language:python
  • 모든 네임스페이스
Any time
  • Any time
  • 저번 주
  • 저번 달
  • 저번 년도
조회수로 정렬
  • 조회수로 정렬
  • Sort by last modified

전체 텍스트 결과:

포맷팅
7 조회 수, 마지막으로 수정됨: 13개월 전
열 포맷 exam <code python> print('pressed at {pos}'.format(pos=pos)) </code> ==== 포맷팅 ==== "스트링 {0}".format(<파라미터>...) **{0}** 대신 사전식 방법 사용 가능 <code python> >>> print("{item} is color".format(item="apple")) >>> dic = {"item":"apple", "color":"red"} print("{0[item]} is {0[color]}".format(dic)) </code> 지역변수를 사전 형식으로 사용 가능. locals() 사용 <
문법요소
6 조회 수, 마지막으로 수정됨: 13개월 전
* zfill() : 0으로 채우기 ==== 포맷팅 ==== "스트링 {0}".format(<파라미터>...) **{0}** 대신 사전식 방법 사용 가능 <code python> >>> print("{item} is color".format(item="apple")) >>> dic = {"item":"apple", "color":"red"} print("{0[item]} is {0[color]}".format(dic)) </code> 지역변수를 사전 형식으로 사용 가능. locals() 사용 <... color = "red" >>> print("{0[item]} is {0[color]}".format(locals())) </code> 사전자료형을 쓰는 경우, 앞에 <nowiki>**</
print 함수의 변경
3 조회 수, 마지막으로 수정됨: 13개월 전
# 문자열 포맷 exam # >>> var1 = 3.14 >>> print('Number Format: {v1}'.format(v1=var1)) Number Format: 3.114 </code> ===== long이 사라지고 int로 통일 ===== <code python> >>> type(2*3030) <c
Installation
1 조회 수, 마지막으로 수정됨: 13개월 전
(self, instance, pos): print('pressed at {pos}'.format(pos=pos)) </code> ===== 커스텀 Custom 프로퍼티 ===== ?

문서 도구

  • 문서 보기
  • 이전 판
  • 역링크
  • 맨 위로
별도로 명시하지 않을 경우, 이 위키의 내용은 다음 라이선스에 따라 사용할 수 있습니다: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki