<jupyter_start><jupyter_text>negative indexing<jupyter_code>s="abc"
print(s[0])
print(s[-1])
print(s[-3])<jupyter_output>a
c
a<jupyter_text>slicing<jupyter_code>s="abcdefg"
print(s[1:3])
print(s[-3:-1])
print(s[1:])
print(s[:3])
print(s[:])<jupyter_output>bc
ef
bcdefg
abc
abcdefg
{'fraction_non_alphanumeric': 0.21785714285714286, 'fraction_numerical': 0.03214285714285714, 'mean_word_length': 13.05, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '286813', 'license': 'MIT', 'n_tokens_mistral': 150, 'n_tokens_neox': 148, 'n_words': 16, 'path': 'Lecture 1 Python Basics/String Slicing/String Slicing-checkpoint.ipynb', 'repo_name': 'Paraskk/Data-Science-and-Machine-Leaning-', 'size': '280'}