xxxxxxxxxx
#this is the speical char list
symbols = {'~', ':', "'", '+', '[', '\\', '@', '^', '{', '%', '(', '-', '"', '*', '|', ',', '&', '<', '`', '}', '.', '_', '=', ']', '!', '>', ';', '?', '#', '$', ')', '/'}
print(symbols)
xxxxxxxxxx
# Using escape sequences
string_with_special_chars = "This string has a double quote: \" and a backslash: \\"
print(string_with_special_chars) # Output: This string has a double quote: " and a backslash: \
# Using string literals with an 'r' prefix
string_with_special_chars = r'This string has a double quote: " and a backslash: \\'
print(string_with_special_chars) # Output: This string has a double quote: " and a backslash: \\