Study Notes (03): Python Interview 100 talking about (based Python3.x) - a variety of connections between the various types of variables and values ...

Learning immediately: https://edu.csdn.net/course/play/26755/340111?utm_source=blogtoedu

String concatenation manner

1. “+”

2. s = "hello" "world" (+ may be omitted)

3. "" connected, standard output redirection

4. Format s = '<% s> <% s>'% (s1, s2)

5. join connector

 s = "" .join ([s1, s2]) "" for the connector

 

The non-character string connection

1. “+”

2. Format

3. Redirection

 

String object connector

Str rewrite method

 

Published 18 original articles · won praise 6 · views 20000 +

Guess you like

Origin blog.csdn.net/weixin_39938635/article/details/104275854