Python Practice Example 86

Python 100例Python 100 Examples

Question:Program to concatenate two strings.

Program analysis:None.

Example (Python 2.0+)

#!/usr/bin/python # -*- coding: UTF-8 -*- if __name__ == '__main__': a = "acegikm" b = "bdfhjlnpq" # Concatenate strings c = a + b print c

The output of the above example is:

acegikmbdfhjlnpq

Python 100例Python 100 Examples

Other extensions