CSC148H1 Lecture Notes - Lecture 14: Init

75 views4 pages
School
Course
Professor
katrinasavvy and 38715 others unlocked
CSC148H1 Full Course Notes
1
CSC148H1 Full Course Notes
Verified Note
1 document

Document Summary

References: code seen in the pictures can be found on the csc148 website: http://www. teach. cs. toronto. edu/~csc148h/winter. Special methods: __init_, __str_, __eq__, etc. Inherit methods -> use unchanged: declare class son(father, extend methods -> extend use, override -> replace completely. Test, exceptions: won"t need to write unittest classes/methods, know exception hierarchy. Adts, stacks, queues, sacks: familiar with add/remove/is_empty. Code should fit in the space provided. Search for a phrase in a list of words. Print true if lo" in any of the words in l. Because lo" is in hello", this prints true. Print true for l" in all of the words in l. Since every single world has l", this will print true. If one word doesn"t fit this condition, false will be printed. What makes a sudoku a square valid: valid rows, valid columns, valid subsquares. To code a sudoku, follow the top-down design. Make each method readable -> not too many lines.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents