Added parentheses to lines 307, 308, 309, 314, 315, 320, 321, 326 for print function to work (#24097)
This commit is contained in:
		
				
					committed by
					
						 Christopher McCormack
						Christopher McCormack
					
				
			
			
				
	
			
			
			
						parent
						
							a50c6edd30
						
					
				
				
					commit
					0a25bcb6fd
				
			| @@ -301,28 +301,28 @@ Tenga en cuenta que dos valores cuando son iguales, no deben implicar que sean i | |||||||
| ###### Ejemplo de uso | ###### Ejemplo de uso | ||||||
|  |  | ||||||
| ```py | ```py | ||||||
| a = 3  |  a = 3  | ||||||
|  b = 3  |  b = 3  | ||||||
|  c = 4  |  c = 4  | ||||||
|  print a is b # prints True  |  print(a is b) # prints True  | ||||||
|  print a is not b # prints False  |  print(a is not b) # prints False  | ||||||
|  print a is not c # prints True  |  print(a is not c) # prints True  | ||||||
|   |   | ||||||
|  x = 1  |  x = 1  | ||||||
|  y = x  |  y = x  | ||||||
|  z = y  |  z = y  | ||||||
|  print z is 1 # prints True  |  print(z is 1) # prints True  | ||||||
|  print z is x # prints True  |  print(z is x) # prints True  | ||||||
|   |   | ||||||
|  str1 = "FreeCodeCamp"  |  str1 = "FreeCodeCamp"  | ||||||
|  str2 = "FreeCodeCamp"  |  str2 = "FreeCodeCamp"  | ||||||
|   |   | ||||||
|  print str1 is str2 # prints True  |  print(str1 is str2) # prints True  | ||||||
|  print "Code" is str2 # prints False  |  print("Code" is str2) # prints False  | ||||||
|   |   | ||||||
|  a = [10,20,30]  |  a = [10,20,30]  | ||||||
|  b = [10,20,30]  |  b = [10,20,30]  | ||||||
|   |   | ||||||
|  print a is b # prints False (since lists are mutable in Python)  |  print(a is b) # prints False (since lists are mutable in Python)  | ||||||
|  |  | ||||||
| ``` | ``` | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user