Starting Out with Python 3rd Edition Gaddis Test Bank download
Starting Out with Python 3rd Edition Gaddis Test Bank download
https://testbankfan.com/product/starting-out-with-python-3rd-
edition-gaddis-test-bank/
https://testbankfan.com/product/starting-out-with-python-3rd-
edition-gaddis-solutions-manual/
https://testbankfan.com/product/starting-out-with-python-4th-
edition-gaddis-test-bank/
https://testbankfan.com/product/starting-out-with-python-2nd-
edition-gaddis-solutions-manual/
https://testbankfan.com/product/starting-out-with-alice-3rd-
edition-tony-gaddis-test-bank/
Starting Out with Visual Basic 7th Edition Gaddis Test
Bank
https://testbankfan.com/product/starting-out-with-visual-
basic-7th-edition-gaddis-test-bank/
https://testbankfan.com/product/starting-out-with-visual-c-4th-
edition-gaddis-test-bank/
https://testbankfan.com/product/starting-out-with-programming-
logic-and-design-3rd-edition-tony-gaddis-test-bank/
https://testbankfan.com/product/starting-out-with-c-early-
objects-9th-edition-gaddis-test-bank/
https://testbankfan.com/product/starting-out-with-java-early-
objects-6th-edition-gaddis-test-bank/
Gaddis: Starting Out with Python, 3e - Test Bank
Chapter Seven
MULTIPLE CHOICE
1. What are the data items in the list called?
a. data
b. elements
c. items
d. values
ANS: B
2. Which list will be referenced by the variable number after the execution of the following code?
number = range(0, 9, 2)
a. [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
b. [1, 3, 5, 7, 9]
c. [2, 4, 6, 8]
d. [0, 2, 4, 6, 8]
ANS: D
ANS: A
ANS: B
5. What method can be used to place an item in the list at a specific index?
a. append
b. index
c. insert
d. Add
ANS: C
6. What would be the value of the variable list after the execution of the following code?
list = [1, 2]
list = list * 3
a. [1, 2] * 3
Gaddis: Starting Out with Python, 3e - Test Bank, Chapter Seven 2
b. [3, 6]
c. [1, 2, 1, 2, 1, 2]
d. [[1, 2], [1, 2], [1, 2]]
ANS: C
7. What would be the value of the variable list after the execution of the following code?
list = [1, 2, 3, 4]
list[3] = 10
a. [1, 2, 3, 10]
b. [1, 2, 10, 4]
c. [1, 10, 10, 10]
d. invalid code
ANS: A
ANS: B
9. What would be the value of the variable list2 after the execution of the following code?
list1 = [1, 2, 3]
list2 = list1
list1 = [4, 5, 6]
a. [1, 2, 3]
b. [4, 5, 6]
c. [1, 2, 3, 4, 5, 6]
d. invalid code
ANS: B
10. What would be the value of the variable list2 after the execution of the following code?
list1 = [1, 2, 3]
list2 = []
for element in list1
list2.append(element)
list1 = [4, 5, 6]
a. [1, 2, 3]
b. [4, 5, 6]
c. [1, 2, 3, 4, 5, 6]
d. invalid code
ANS: A
Gaddis: Starting Out with Python, 3e - Test Bank, Chapter Seven 3
11. When working with multiple sets of data, one would typically use a(n) _____.
a. list
b. tuple
c. nested list
d. Sequence
ANS: C
12. The primary difference between a tuple and list is that _____.
a. when creating a tuple you don’t use commas to separate elements
b. a tuple can only include string elements
c. a tuple cannot include lists as elements
d. once a tuple is created, it cannot be changed
ANS: D
ANS: C
ANS: B
ANS: D
TRUE/FALSE
1. True/False: Invalid indexes do not cause slicing expressions to raise an exception.
ANS: T
Gaddis: Starting Out with Python, 3e - Test Bank, Chapter Seven 4
2. True/False: Lists are dynamic data structures such that items may be added to them or
removed from them.
ANS: T
3. True/False: Arrays, which most other programming languages allow, have much more
capabilities than list structures.
ANS: F
ANS: F
5. True/False: The remove method removes all occurrences of the item from a list.
ANS: F
6. True/False: The sort method rearranges the elements of a list so they appear in ascending or
descending order.
ANS: F
7. True/False: The first step in calculating the average of the values in a list is to get the total of the
values.
ANS: T
8. True/False: Indexing starts at 1, so the index of the first element is 1, the index of the second
element is 2, and so forth.
ANS: F
ANS: T
10. True/False: In slicing, if the end index specifies a position beyond the end of the list, Python will
use the length of the list instead.
ANS: T
ANS: sequence
Gaddis: Starting Out with Python, 3e - Test Bank, Chapter Seven 5
2. Each element in a tuple has a(n) _______________ that specifies its position in the tuple.
ANS: index
ANS: len
4. Tuples are _______________ sequences, which means that once a tuple is created, it cannot
be changed.
ANS: immutable
ANS: slice
ANS: mutable
ANS: append
8. The _______________ exception is raised when a search item is not in the list being searched.
ANS: ValueError
9. The _______________ method reverses the order of the items in the list.
ANS: reverse
10. The _______________ function returns the item that has the lowest value in the sequence.
ANS: min
Exploring the Variety of Random
Documents with Different Content
11. They differ from us something in the creede too, for if they get
the goods of one, that is without, into their hands, hee shall be kept
without remedy for any satisfaction: and they beleeve that this is not
cosenage.[556]
12. And lastly they differ from us in the manner of praying; for they
winke[557] when they pray, because they thinke themselves so
perfect in the highe way to heaven that they can find it blindfould:
so doe not I.[558]
Chap. XXVIII.
1. Prooving New England the principall part of all America, and most
commodious and fit for a habitation and generation.
5. Of their Religion.
7. Of their Childbearing.
8. Of their reverence and respect to age.
16. How the nine Worthies of New Canaan put mine Host of Ma-re-
Mount into an inchaunted Castle.
31. How mine Host of Ma-re-Mount played Jonas after hee got out
of the Whales belly.
FINIS.
THE PRINCE SOCIETY.
OFFICERS
OF
THE PRINCE SOCIETY.
1883.
President.
THE REV. EDMUND F. SLAFTER, A.M. Boston, Mass.
Vice-Presidents.
JOHN WARD DEAN, A.M. Boston, Mass.
WILLIAM B. TRASK, Esq. Boston, Mass.
THE HON. CHARLES H. BELL, LL.D. Exeter, N.H.
JOHN MARSHALL BROWN, A.M. Portland, Me.
Corresponding Secretary.
THE REV. HENRY W. FOOTE, A.M. Boston, Mass.
Recording Secretary.
DAVID GREENE HASKINS, Jr., A.M. Cambridge, Mass.
Treasurer.
ELBRIDGE H. GOSS, Esq. Boston, Mass.
THE PRINCE SOCIETY.
1883.
The Hon. Charles Francis Adams, LL.D. Boston, Mass.
Charles Francis Adams, Jr., A.B. Quincy, Mass.
Thomas Coffin Amory, A.M. Boston, Mass.
William Sumner Appleton, A.M. Boston, Mass.
Walter T. Avery, Esq. New York, N.Y.
Mr. Thomas Willing Balch Philadelphia, Pa.
George L. Balcom, Esq. Claremont, N.H.
Charles Candee Baldwin, M.A. Cleveland, Ohio.
Samuel L. M. Barlow, Esq. New York, N.Y.
James Phinney Baxter, A.M. Portland, Me.
The Hon. Charles H. Bell, LL.D. Exeter, N.H.
John J. Bell, A.M. Exeter, N.H.
Samuel Lane Boardman, Esq. Boston, Mass.
The Hon. James Ware Bradbury, LL.D. Augusta, Me.
J. Carson Brevoort, LL.D. Brooklyn, N.Y.
The Rev. Phillips Brooks, D.D. Boston, Mass.
Sidney Brooks, A.M. Boston, Mass.
Horace Brown, A.B., LL.B. Salem, Mass.
Mrs. John Carter Brown Providence, R.I.
John Marshall Brown, A.M. Portland, Me.
Joseph O. Brown, Esq. New York, N.Y.
Philip Henry Brown, A.M. Portland, Me.
Thomas O. H. P. Burnham, Esq. Boston, Mass.
George Bement Butler, Esq. New York, N.Y.
The Hon. Mellen Chamberlain, A.M. Chelsea, Mass.
The Hon. William Eaton Chandler, A.M. Washington, D.C.
George Bigelow Chafe, A.M. Boston, Mass.
Clarence H. Clark, Esq. Philadelphia, Pa.
Gen. John S. Clark Auburn, N.Y.
The Hon. Samuel Crocker Cobb Boston, Mass.
Ethan N. Coburn, Esq. Charlestown, Mass.
Jeremiah Colburn, A.M. Boston, Mass.
Deloraine P. Corey, Esq. Boston, Mass.
Erastus Corning, Esq. Albany, N.Y.
Ellery Bicknell Crane, Esq. Worcester, Mass.
Abram E. Cutter, Esq. Charlestown, Mass.
William M. Darlington, Esq. Pittsburg, Pa.
John Ward Dean, A.M. Boston, Mass.
Charles Deane, LL.D. Cambridge, Mass.
Edward Denham, Esq. New Bedford, Mass.
John Charles Dent, Esq. Toronto, Canada.
Prof. Franklin B. Dexter, A.M. New Haven, Ct.
The Rev. Henry Martyn Dexter, D.D. Boston, Mass.
Samuel Adams Drake, Esq. Melrose, Mass.
Henry Thayer Drowne, Esq. New York, N.Y.
Henry H. Edes, Esq. Charlestown, Mass.
Jonathan Edwards, A.B., M.D. New Haven, Ct.
William Henry Egle, A.M, M.D. Harrisburgh, Pa.
Janus G. Elder, Esq. Lewiston, Me.
Samuel Eliot, LL.D. Boston, Mass.
Alfred Langdon Elwyn, M.D. Philadelphia, Pa.
James Emott, Esq. New York, N.Y.
The Hon. William M. Evarts, LL. D. New York, N.Y.
Joseph Story Fay, Esq. Woods Holl, Mass.
John S. H. Fogg, M.D. Boston, Mass.
The Rev. Henry W. Foote, A.M. Boston, Mass.
Samuel P. Fowler, Esq. Danvers, Mass.
James E. Gale, Esq. Haverhill, Mass.
Isaac D. Garfield, Esq. Syracuse, N.Y.
Marcus D. Gilman, Esq. Montpelier, Vt.
The Hon. John E. Godfrey Bangor, Me.
Abner C. Goodell, Jr., A.M. Salem, Mass.
Elbridge H. Goss, Esq. Boston, Mass.
The Hon. Justice Horace Gray, LL.D. Boston, Mass.
William W. Greenough, A.B. Boston, Mass.
Isaac J. Greenwood, A.M. New York, N.Y.
Charles H. Guild, Esq. Somerville, Mass.
David Greene Haskins, Jr., A.M. Cambridge, Mass.
The Hon. Francis B. Hayes, A.M. Boston, Mass.
The Hon. Rutherford B. Hayes, LL.D. Fremont, Ohio.
Thomas Wentworth Higginson, A.M. Cambridge, Mass.
W. Scott Hill, M.D. Augusta, Me.
James F. Hunnewell, Esq. Charlestown, Mass.
Theodore Irwin, Esq. Oswego, N.Y.
The Rev. Henry Fitch Jenks, A.M. Lawrence, Mass.
The Hon. Clark Jillson Worcester, Mass.
Mr. Sawyer Junior Nashua, N.H.
George Lamb, Esq. Boston, Mass.
Edward F. De Lancey, Esq. New York, N.Y.
William B. Lapham, M.D. Augusta, Me.
Henry Lee, A.M. Boston, Mass.
John A. Lewis, Esq. Boston, Mass.
Henry Cabot Lodge, Ph.D. Boston, Mass.
Orsamus H. Marshall, Esq. Buffalo, N.Y.
William T. R. Marvin, A.M. Boston, Mass.
William F. Matchett, Esq. Boston, Mass.
Frederic W. G. May, Esq. Boston, Mass.
John Norris McClintock, A.M. Concord, N.H.
The Rev. James H. Means, D.D. Boston, Mass.
George H. Moore, LL.D. New York, N.Y.
The Rev. James De Normandie, A.M. Boston, Mass.
Prof. Charles E. Norton, A.M. Cambridge, Mass.
John H. Osborne, Esq. Auburn, N.Y.
George T. Paine, Esq. Providence, R.I.
Nathaniel Paine, Esq. Worcester, Mass.
John Carver Palfrey, A.M. Boston, Mass.
Daniel Parish, Jr., Esq. New York, N.Y.
Francis Parkman, LL.D. Boston, Mass.
Augustus T. Perkins, A.M. Boston, Mass.
The Rt. Rev. William Stevens Perry, D.D., LL.D. Davenport, Iowa.
William Frederic Poole, LL.D. Chicago, Ill.
Rear Admiral George Henry Preble, U. S. N. Brookline, Mass.
Samuel S. Purple, M.D. New York, N.Y.
Edward Ashton Rollins, A.M. Philadelphia, Pa.
The Hon. Nathaniel Foster Safford, A.M. Milton, Mass.
Joshua Montgomery Sears, A.B. Boston, Mass.
John Gilmary Shea, LL.D. Elizabeth, N.J.
The Hon. Mark Skinner Chicago, Ill.
The Rev. Carlos Slafter, A.M. Boston, Mass.
The Rev. Edmund F. Slafter, A.M. Boston, Mass.
Charles C. Smith, Esq. Boston, Mass.
Oliver Bliss Stebbins, Esq. Boston, Mass.
George Stevens, Esq. Lowell, Mass.
George Stewart, Jr., Esq. Quebec, Canada.
Russell Sturgis, A.M. London, Eng.
William B. Trask, Esq. Boston, Mass.
Joseph B. Walker, A.M. Concord, N.H.
William Henry Wardwell, Esq. Boston, Mass.
Miss Rachel Wetherill Philadelphia, Pa.
Henry Wheatland, A.M., M.D. Salem, Mass.
John Gardner White, A.M. Cambridge, Mass.
William Adee Whitehead, A.M. Newark, N.J.
William H. Whitmore, A.M. Boston, Mass.
Henry Austin Whitney, A.M. Boston, Mass.
The Hon. Marshall P. Wilder, Ph.D. Boston, Mass.
Henry Winsor, Esq. Philadelphia, Pa.
The Hon. Robert C. Winthrop, LL.D. Boston, Mass.
Charles Levi Woodbury, Esq. Boston, Mass.
Ashbel Woodward, M.D. Franklin, Ct.
J. Otis Woodward, Esq. Albany, N.Y.
LIBRARIES.
VOLUMES IN PREPARATION.
1. Captain John Mason, the founder of New Hampshire, including his
Tract on Newfoundland, 1620, the several American Charters in
which he was a Grantee, and other papers; and a Memoir by the late
Charles W. Tuttle, Ph.D. Edited, with historical illustrations, by John
Ward Dean, A.M.
2. Sir Ferdinando Gorges, including his Tract entitled A Brief Narration,
1658, American Charters granted to him, and other papers; with
historical Illustrations and a Memoir by the Rev. Edmund F. Slafter,
A.M.
3. Sir Humphrey Gilbert, including his Discourse to prove a Passage by
the North-West to Cathaia and the East Indies; his Letters Patent to
discover and possess lands in North America, granted by Queen
Elizabeth, June 11, 1578. With historical Illustrations and a Memoir.
4. Sir Walter Ralegh and his Colony in America. Containing the Royal
Charter of Queen Elizabeth to Sir Walter Ralegh for discovering and
planting of new lands and countries, March 25, 1584, with letters,
discourses, and narratives of the Voyages made to Virginia at his
charges, with original descriptions of the country, commodities, and
inhabitants. Edited, with a Memoir and historical illustrations, by the
Rev. Increase N. Tarbox, D.D.
INDEX.
INDEX.
A.
Aberdecest, 130, n.
Acomenticus:
charter granted to, by Gorges, 81;
Morton dies at, 91.
Adams, John:
on name of Merry-Mount, 14, n.;
on fate of Wollaston, 15;
on Thomas Morton, 95, n.;
injuries to library of, 101, n.
Adams, John Q., 101.
Adders, 213.
Ælianus, 345, n.
Air of New England, 121, 137, 177, 190.
Alcides, 292.
Alecto, 275.
Alexander, Sir William, quoted, 140, 167.
Alder, the, 186.
Allen, J. A., notes on wild animals of New England by, 199-215.
Allerton, Isaac:
his course toward Morton in England, 35, 303;
his mission to England in 1629, 36;
carries Morton back to Plymouth, 36;
tries to obtain charter for Plymouth, 52;
brings over goods, 289, n.
Allize, 225.
Alsatian Squire, the, 92.
Amphitrite, 277, 281.
Animals, wild of New England, chapter on, 199-215.
Antinomian controversy, 81, 323, n.
Antonomasia, 316.
Anúnime, 123, n.
Arbor-vitæ, 185, n.
Archimedes, 291.
Argus eyes, 303.
Aristotle, cited, 117, 118.
Armoniack, 219.
Arms. (See Fire-arms.)
Arthur’s Table, King, 290.
Arundel, Earl of, 60, 70.
Ascowke, 213.
Ash, the, 183.
Aspinwall, William, 319, n.
Audubon, John James, quoted, 131, n., 192, n.
Auk, the great, formerly found in Boston Bay, 131, n.
B.
Bacchanal Triumph, poem, 290-4.
Bagnall, Walter, 22, 206, n., 218, n.
Baptism, 331, n.
“Barren doe, the,” 94, 264-6, 272-7.
Barrowe, Henry, on Common Prayer, 332, n.
Bass, 222.
Beach, the, 183.
Bears: used by Indians, 142-4;
value of skins of, 205;
description of, 209;
Indian methods of hunting, 210;
flesh of, 210.
Beaver: value of skins of, 22, 205, 295;
gain in, 32, 282;
regulation of trade in, 39, 306;
virtues of tails of, 162, 205;
description of, 204;
muskrats passed for, 211;
Dutch trade in, 239, n.;
a theft compounded in, 269;
plenty of, at Nipnet, 270;
compared to Jason’s Fleece, 295.
Bible, the, 94, 212, 260.
Bibliography of New Canaan, 99.
Billington, John, 217.
Birch, the, 186.