Python

 

RESEARCH: Expand your knowledge of the print() function.  

  1. Write a Python program to print the following string in a specific format (see the Picture below)

String: “Twinkle Twinkle: little How I wonder what you are! Up above the world so high: Like a diamond in the sky Twinkle Twinkle: little star: How I wonder what y al are.”

Twinkle.JPG

2. Can “Twinkle: Twinkle: little star” be performed as a musical cannon? 

3. Write a Python program to count the number (occurrences) of t-s (upper and lower cases) in the string.

4. Write a Python program to count the number (occurrences) of i’s, w’s and l’s in the string.