TORONTO KIDS COMPUTER CLUB | admin
1
archive,paged,author,author-admin,author-1,paged-46,author-paged-46,ajax_fade,page_not_loaded,,qode-theme-ver-7.6.2,wpb-js-composer js-comp-ver-6.10.0,vc_responsive

Author: admin

16 Apr Aurora Wednesday 18:30 Python Practice 22.04.13.

Question: Alice took a clean sheet of paper and drew h horizontal and v vertical lines onto the paper. The horizontal lines have y-coordinates y1,…,yh, and the vertical lines have x-coordinates x1,…,xv. Given these coordinates, count the number of squares that appeared on the paper. (The whole boundary of the square has to be drawn. The inside...

Read More

15 Apr Aurora Monday 18:30 Python Homework 22.04.11.

Question 1: Use recursion to write a function divides_all that consumes a list of positive integers seq and a positive integer factor. Your function should produce True if every item in seq is a multiple of factor and False otherwise. The helper function is_multiple has been provided for you. Question 2: Use recursion to write a function reverse that consumes a list seq and produces a new...

Read More