COMPSCI 61A Lecture Notes - Lecture 10: Concatenation

17 views6 pages
zogo39484755 and 6 others unlocked
COMPSCI 61A Full Course Notes
22
COMPSCI 61A Full Course Notes
Verified Note
22 documents

Document Summary

Entries in the completely optional hog contest due monday 9/19 @ 11:59pm. Homework party wednesday 9/21 6:30pm-8:30pm in 247 cory hall. Bonus point for submission by wednesday 9/28 @ 11:59pm. Project party wednesday 9/28 6:30-8:30pm in 247 cory hall. The midterm 1 exam and solutions are posted. Built-in data type in python that"s used pretty much everywhere. Lists can be initialized as odds = [41, 43, 47, 49] Selection of elements by index digits[i] getitem(digits, i) [2, 7] + digits * 2 add([2, 7], mul(digits, 2)) Nested lists pairs = [[10, 20], [30, 40]] Built-in operators for testing whether an element appears in a compound value digits = [1, 8, 2, 8] [1, 2] in [3, [1, 2], 4] => true. [1, 2] in [3, [[1, 2]], 4] => false. For statements reduce the amount of code necessary to traverse through the list.

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