Merge pull request #858 from j127/patch-1

Update structure.rst - fix indentation bug
This commit is contained in:
2017-11-13 22:01:14 -05:00
committed by GitHub
+2 -2
View File
@@ -811,7 +811,7 @@ The map function can be even faster than a list comprehension in some cases.
# create a concatenated string from 0 to 19 (e.g. "012..1819")
nums = ""
for n in range(20):
nums += str(n) # slow and inefficient
nums += str(n) # slow and inefficient
print nums
**Good**
@@ -821,7 +821,7 @@ The map function can be even faster than a list comprehension in some cases.
# create a concatenated string from 0 to 19 (e.g. "012..1819")
nums = []
for n in range(20):
nums.append(str(n))
nums.append(str(n))
print "".join(nums) # much more efficient
**Better**