Skip to content

Latest commit

 

History

History
17 lines (15 loc) · 649 Bytes

Strings-string-functions-Python.md

File metadata and controls

17 lines (15 loc) · 649 Bytes
layout topic title language
exercise
Strings
string Functions
Python

Use functions from the string module or from base Python to print the following strings.

  1. 'species' in all capital letters
  2. 'gcagtctgaggattccaccttctacctgggagagaggacatactatatcgcagcagtggaggtggaatgg' with all of the occurrences of 'a' replaced with 'A'
  3. "    Thank goodness it's Friday" without the leading white space (i.e., without the spaces before Thank)
  4. The number of 'a's in 'gccgatgtacatggaatatacttttcaggaaacacatatctgtggagagg'.
  5. Print the length of this dna sequence 'gccgatgtacatggaatatacttttcaggaaacacatatctgtggagagg'