Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Library for removal of punctuation and defining function

#removing punctuations
#library that contains punctuation
import string
string.punctuation

#defining the function to remove punctuation
def remove_punctuation(text):
  if(type(text)==float):
    return text
  ans=""  
  for i in text:     
    if i not in string.punctuation:
      ans+=i    
  return ans
 
PREVIOUS NEXT
Tagged: #Library #removal #punctuation #defining #function
ADD COMMENT
Topic
Name
2+4 =