TORONTO KIDS COMPUTER CLUB | admin
1

## 25 AprMarkham Saturday 15:30 Python Homework 20.04.18.

Question: Jack is sending a super special love letter, and because it is so special he doesn’t want anyone (except his crush obviously) to see it. To stop it from getting into the wrong hands, he has decided to encrypt the letter with a Caeser Cipher (don’t...

## 25 AprMarkham Saturday 14:00 Java Homework 20.04.18.

Question: Jack is depositing money! Every year, Jack puts N coins into his bank account. At the end of each year, Jack’s investments will grow by P percent, rounded down to the nearest coin. After Y years, he would like to have at least T coins in his bank account so that he can buy some...

## 25 AprPMCA Saturday 18:30 Python Homework 20.04.18.

Question： The Body Mass Index (BMI) is one of the calculations used by doctors to assess an adult’s health. The doctor measures the patient’s height (in meters) and weight (in kilograms), then calculates the BMI using the formula BMI = weight / (height * height) Write a program which...

## 24 AprAurora Wednesday Saturday Python Homework 20.04.22.

Question 1： Using split and join function of the list to change string “green,red,yellow,blue,” into string: “green light* red light* yellow light* blue light* “ Hint: >>> vegetables = “carrots, potatoes, onions, leeks, celery” >>> vegetables = vegetables.split(“, “) >>> vegetables [‘carrots’, ‘potatoes’, ‘onions’, ‘leeks’, ‘celery’] >>> fruits = [‘avocados’, ‘bananas’, ‘oranges’, ‘grapes’, ‘mangoes’] >>>“, “.join(fruit) >>> ‘avocados, bananas, oranges, grapes, mangoes’ Question 2： Create a list called...

## 22 AprAurora Tuesday 18:30 Python Homework 20.04.21.

Question: Write a program for a movie theater using while loop. It will keep asking your age and display the ticket price, until you enter “quit”. It is free if you are less than 3 years old, otherwise if your age is less than 16 years...

## 21 AprAurora Monday 18:30 Python Homework 20.04.20.

Question: You are given a string . Suppose a character ‘a’ occurs consecutively n times in the string. Replace these consecutive occurrences of the character ‘a’ with (n, ‘a’) in the string. Input Format:  A single line of input consisting of the string . Output Format: A single line of...

## 21 AprAurora Saturday 16:30 Python Homework 20.04.18.

Question 1: We have a list of following: zoo = [‘monkeys’, ‘tigers’, ‘pandas’, ‘penguins’, ‘giraffes’, ‘hippos’, ‘bears’] how to retrieve a slice of list zoo, so you can get the following result? [‘monkeys’, ‘pandas’, ‘giraffes’, ‘bears’] Question 2: from the same list of zoo in the question 1, how to retrieve a slice...

## 21 AprAurora Saturday 14:30 Python Homework 20.04.18.

Question:You might be surprised to know that 2013 is the first year since 1987 with distinct digits. The years 2014, 2015, 2016, 2017, 2018, 2019 each have distinct digits. 2012 does not have distinct digits, since the digit 2 is repeated. Given a year, what is...

## 20 AprAurora Tuesday 18:30 Python Homework 20.04.14.

Question 1: Factorial of any number n is represented by n! and is equal to 1*2*3*...

## 20 AprMarkham Saturday 9:30 Python Homework 20.04.18.

Question: Modify the program we made in the class. Add starting screen as below, the real game will start when play click the mouse in the range of the “PLAY” button. (Scroll down for more hint) You can download the background images from below: The size of the...