Assignments for Today

Middle Characters

Create a program that:

  • Takes a string as an input
  • If the length of the string is divisible by 2, print the middle 2 characters
    • Hint: Use this this article.
  • Else, print the middle character

Choose Your Own Adventure

Have you ever played a Choose Your Own Adventure game on your phone or read the Choose Your Own Adventure series? If not, take a minute to look it up and get familiar with the concept because today you will be writing your own!

  • Print out the beginning of a story. Be as creative as you want!
  • Give the user at least 3 options
  • Print out different results depending on the user’s choice

For this project, write at least 5 different sets of choices for the user. Share your programs in Slack so other students can play!