Home > other >  An introduction to a small white want to consult with python
An introduction to a small white want to consult with python

Time:09-26

Formatted string is what meaning, please forrmat () method to create templates and placeholder is why, to create the template what good ah, who can help answer, thank you very much

CodePudding user response:

It's specific problems can be baidu: Python formatted string

Look at some examples can understand

 

Name=input (" please enter your name:)
Num=5
Print (' congratulations' + name + 'win' + STR (num) + 'kill! ')

# to use. The format ()
Name=input (" please input your name:)
Num=5
Print (' congratulations with {} {} kill! 'the format (name, num))

CodePudding user response:

Create templates and format for the output to a file or screen cleaner, the formatting is according to the fixed format of the output

CodePudding user response:

reference weixin_45903952 reply: 3/f
create templates and format for the output to a file or screen cleaner, the formatting is a fixed format output

The placeholder, please create the template is specifically how to understand, thank you

CodePudding user response:

Llllttttyyy
reference 4 floor response:
Quote: refer to the third floor weixin_45903952 response:
create templates and format for the output to a file or screen cleaner, the formatting is a fixed format output

The placeholder, please create the template is specifically how to understand, thank you


Placeholder is your output character width, rather then a fixed value, the characters written to the specified width, thus more clean, not random

CodePudding user response:

reference 5 floor weixin_45903952 reply:
Quote: refer to 4th floor llllttttyyy response:

Quote: refer to the third floor weixin_45903952 response:
create templates and format for the output to a file or screen cleaner, the formatting is a fixed format output

The placeholder, please create the template is specifically how to understand, thank you


Placeholder is your output character width, rather then a fixed value, the characters written to the specified width, thus more clean, not disorderly

So to speak, a placeholder is equivalent to a framework that is given a certain width, character to fill in it, so to understand

CodePudding user response:

reference 5 floor weixin_45903952 reply:
Quote: refer to 4th floor llllttttyyy response:

Quote: refer to the third floor weixin_45903952 response:
create templates and format for the output to a file or screen cleaner, the formatting is a fixed format output

The placeholder, please create the template is specifically how to understand, thank you


Placeholder is your output character width, rather then a fixed value, the characters written to the specified width, thus more clean, not disorderly

Thank you very much for this doubt, thank you

CodePudding user response:

refer to 6th floor llllttttyyy response:
Quote: refer to the 5 floor weixin_45903952 response:
Quote: refer to 4th floor llllttttyyy response:

Quote: refer to the third floor weixin_45903952 response:
create templates and format for the output to a file or screen cleaner, the formatting is a fixed format output

The placeholder, please create the template is specifically how to understand, thank you


Placeholder is your output character width, rather then a fixed value, the characters written to the specified width, thus more clean, not disorderly

So to speak, a placeholder is equivalent to a framework that is given a certain width, character to fill in it, so to understand it


Can understand so, equivalent to a fixed table, to fill in the words, don't change the structure of a table
  • Related