How to write a string when there are multiple lines in python

Introduction

I'm thinking of inputting all at once with a competition pro

Method

multi_line = """ 
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
Yeah yeah yeah yeah yeah yeah yeah
"""

Recommended Posts

How to write a string when there are multiple lines in python
How to write string concatenation in multiple lines in Python
How to embed a variable in a python string
How to convert / restore a string with [] in python
[Python] How to expand variables in a character string
How to slice a block multiple array from a multiple array in Python
How to define multiple variables in a python for statement
How to get a stacktrace in python
How to write Ruby to_s in Python
How to make a string into an array or an array into a string in Python
[Introduction to Python] How to output a character string in a Print statement
How to get a string from a command line argument in python
Timezone specification when converting a string to datetime type in python
How to delete multiple specified positions (indexes) in a Python list
How to turn the for statement when there are multiple values for one key in the dictionary
python> How to write multiple lines> How to write in mnist_with_summaries.py> It seems that there is no need for line concatenation symbols
How to clear tuples in a list (Python)
How to create a JSON file in Python
Python Note: When assigning a value to a string
How to notify a Discord channel in Python
[Introduction to Python] How to write a character string with the format function
[Python] How to draw a histogram in Matplotlib
How to write a named tuple document in 2020
When you want to replace multiple characters in a string without using regular expressions in python3 series
Memorandum Regular expression When there are multiple characters in the character string that you want to separate
How to take multiple arguments when doing parallel processing using multiprocessing in python
20th Offline Real-time How to Write Problems in Python
Parse a JSON string written to a file in Python
I want to embed a variable in a Python string
I want to write in Python! (2) Let's write a test
When there are multiple Selenium SeleniumBasic classes (Python VBA)
How to write a list / dictionary type of Python3
[Python] How to write a docstring that conforms to PEP8
How to exit when using Python in Terminal (Mac)
How to retrieve multiple arrays using slice in python.
How to execute a command using subprocess in Python
How to develop in Python
A story about how to specify a relative path in python.
How to use the __call__ method in a Python class
[Python] How to write an if statement in one sentence.
A simple way to avoid multiple for loops in Python
I tried "How to get a method decorated in Python"
How to develop in a virtual environment of Python [Memo]
How to get the last (last) value in a list in Python
How to get a list of built-in exceptions in python
Python learning basics ~ How to output (display) a character string? ~
How to write a metaclass that supports both python2 and python3
Write a binary search in Python
[Python] How to do PCA in Python
How to write soberly in pandas
How to collect images in Python
How to use SQLite in Python
How to quickly count the frequency of appearance of characters from a character string in Python?
Write a pie chart in Python
Write a vim plugin in Python
Write a depth-first search in Python
How to wrap C in Python
How to use ChemSpider in Python
6 ways to string objects in Python
How to write type hints for variables that are assigned multiple times in one line
How to use PubChem in Python