Introduction to Python: Chapter 4 – Lists and Loops

The video for this session is here

The Jupyter notebook for the session is here

The exercise for this session is as follows:

# 1. Make a file with each line starting with the same sequence at the start
# 2. Call this file dna_with_adapter.txt
# 3. Read in the file and remove the adapter string (ACTAA) from each line
# 4. Write the sequences without the adapter to a new file (dna_without_adapter.txt)
# 5. print to the screen the length of each sequence without the adapter