mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 05:31:20 +00:00 
			
		
		
		
	Fix Issue5416 - explain negative value of maxplit in str.replace.
This commit is contained in:
		
							parent
							
								
									d74ca12fdd
								
							
						
					
					
						commit
						c0548c9d90
					
				
					 1 changed files with 2 additions and 1 deletions
				
			
		|  | @ -513,7 +513,8 @@ def replace(s, old, new, maxsplit=-1): | |||
| 
 | ||||
|     Return a copy of string str with all occurrences of substring | ||||
|     old replaced by new. If the optional argument maxsplit is | ||||
|     given, only the first maxsplit occurrences are replaced. | ||||
|     given, only the first maxsplit occurrences are replaced. A | ||||
|     negative value of maxsplit signifies all occurances. | ||||
| 
 | ||||
|     """ | ||||
|     return s.replace(old, new, maxsplit) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Senthil Kumaran
						Senthil Kumaran