Full Download of Introduction to Programming Using Python 1st Edition Schneider Test Bank in PDF DOCX Format
Full Download of Introduction to Programming Using Python 1st Edition Schneider Test Bank in PDF DOCX Format
https://testbankfan.com/product/introduction-to-programming-using-
python-1st-edition-schneider-solutions-manual/
testbankbell.com
https://testbankfan.com/product/introduction-to-programming-using-
visual-basic-10th-edition-schneider-test-bank/
testbankbell.com
https://testbankfan.com/product/introduction-to-programming-using-
visual-basic-2012-9th-edition-schneider-test-bank/
testbankbell.com
https://testbankfan.com/product/anatomy-and-physiology-foundations-
for-the-health-professions-1st-edition-deborah-roiger-solutions-
manual/
testbankbell.com
Single Variable Calculus Early Transcendentals 8th Edition
Stewart Test Bank
https://testbankfan.com/product/single-variable-calculus-early-
transcendentals-8th-edition-stewart-test-bank/
testbankbell.com
https://testbankfan.com/product/data-analytics-for-accounting-1st-
edition-richardson-test-bank/
testbankbell.com
https://testbankfan.com/product/health-psychology-a-cultural-
approach-3rd-edition-gurung-solutions-manual/
testbankbell.com
https://testbankfan.com/product/college-algebra-3rd-edition-ratti-
test-bank/
testbankbell.com
https://testbankfan.com/product/forecasting-for-economics-and-
business-1st-edition-gloria-gonzalez-rivera-solutions-manual/
testbankbell.com
Starting Out With C++ Early Objects 7th Edition Gaddis
Solutions Manual
https://testbankfan.com/product/starting-out-with-c-early-objects-7th-
edition-gaddis-solutions-manual/
testbankbell.com
Chapter 5
Multiple Choice (21) WARNING: CORRECT ANSWERS ARE IN THE SAME POSITION AND TAGGED WITH **.
YOU SHOULD RANDOMIZE THE LOCATION OF THE CORRECT ANSWERS IN YOUR EXAM.
1. When reading data from a file, the open function returns a(n) __________.
a. file object **
b. file name
c. file handle
d. file tuple
3. After all the lines of a file have been read, the readline method returns __________.
a. the empty string **
b. an empty tuple
c. the value None
d. a Throwback error
4. Python uses a(n) __________ as a temporary holding place for data to be written to disk.
a. buffer **
b. temp space
c. special memory location
d. list
6. Which standard library module do you need to import in order to use the remove and rename
functions for files?
a. os **
b. file
c. path
15. To avoid a potential runtime error when opening files for reading or writing:
a. use the os.path.isfile function **
b. use the os.path.file.exists function
c. prompt the user for the action to take if the file does not exist
d. use the Boolean value try to check if the file exists
18. Each piece of data in a CSV file record is referred to as a(n) __________.
a. field **
b. record
c. tuple
d. line
19. In a dictionary, a pair such such as “dog” : “rover” is called a(n) __________.
a. item **
b. pair
c. key
d. couple
20. Which file format stores data as a sequence of types that can only be access by special readers?
a. binary **
b. text
21. In order for Python to use functions to work with binary files, you must first import which
standard library module?
a. pickle **
b. os
c. binaries
d. osfile
True/False (23)
1. After all the lines of a file have been read, the readline method returns the value None.
Answer: false
2. You must close a file in order to guarantee that all data has been physically written to the disk.
Answer: true
3. The remove and rename functions cannot be used with open files.
Answer: true
Answer: true
Answer: false
Answer: true
Answer: false
Answer: true
Answer: true
Answer: false
11. infile is a descriptive name bot not mandatory for file input usage.
Answer: true
12. An attempt to open a nonexistent file for input generates a syntax error.
Answer: false
13. If a file that already exists is opened for writing, the contents of the file will be erased.
Answer: true
Answer: false
Answer: true
Answer: true
17. The data in the fields of each record in a CSV file normally should be related.
Answer: true
Answer: true
Answer: true
Answer: false
Answer: false
Answer: true
1. Complete the following function to open the file for reading and read the contents into a single
string named contents.
def readFile(file):
Answer:
infile = open(file, ‘r’)
contents = infile.read()
2. Write a Python statement to open a file called names for writing and assign it to a variable called
outfile.
3. Write a Python statement to open a file called grades with the intent to add values to the end of
the file and assign it to a variable called outfile.
4. Write a single Python statement to convert the list [“spring”, “summer”, “fall”, “winter”] to a set
called seasons.
5. Write a single Python statement to convert the tuple (“spring”, “summer”, “fall”, “winter”) to a
set called seasons.
7. Explain the difference between a simple text file and a CSV-formatted file.
Answer: A simple text file has a single piece of data per line. A CSV-formatter file has several items
of data on each line with items separated by commas.
9. Write a Python statement to create a copy of the dictionary called dogs into a new dictionary
called canines.
11. Why can’t lists and sets serve as keys for dictionaries?
Answer: Because dictionary keys must be immutable objects. Lists and sets are mutable.
It can hardly be doubted that the writer from whom Hippolytus here
quotes is referring to the soul or animating principle of the world,
whom he here and elsewhere identifies with the great God of the
Greek mysteries[179]. Hence it was the casting-down to this earth of
Ophiomorphus which gave it life and shape, and thus stamped upon
it the impress of the First Man[180]. As Ophiomorphus was also the
child of Ialdabaoth son of Sophia, the Soul of the World might
therefore properly be said to be drawn from all the three visible
worlds[181].
We come to the creation of man which the Ophites attributed to the
act of Ialdabaoth and the other planetary powers, and represented
as taking place not on the earth, but in some one or other of the
heavens under their sway[182]. According to Irenaeus—here our only
authority—Ialdabaoth boasted that he was God and Father, and that
there was none above him[183]. His mother Sophia or Prunicos,
disgusted at this, cried out that he lied, inasmuch as there was
above him “the Father of all, the First Man and the Son of Man[184]”;
and that Ialdabaoth was thereby led on the counsel of the serpent or
Ophiomorphus to say, “Let us make man in our own image[185]!” Here
the Greek or older text of Irenaeus ends, and our only remaining
guide is the later Latin one, which bears many signs of having been
added to from time to time by some person more zealous for
orthodoxy than accuracy. Such as it is, however, it narrates at a
length which compares very unfavourably with the brevity and
concision of the statements of the Greek text, that Ialdabaoth’s six
planetary powers on his command and at the instigation of Sophia
formed an immense man who could only writhe along the ground
until they carried him to Ialdabaoth who breathed into him the breath
of life, thereby parting with some of the light that was in himself; that
man “having thereby become possessed of intelligence (Nous) and
desire (Enthymesis) abandoned his makers and gave thanks to the
First Man”; that Ialdabaoth on this in order to deprive man of the light
he had given him created Eve out of his own desire; that the other
planetary powers fell in love with her beauty and begot from her sons
who are called angels; and finally, that the serpent induced Adam
and Eve to transgress Ialdabaoth’s command not to eat of the fruit of
the Tree of Knowledge[186]. On their doing so, he cast them out of
Paradise, and threw them down to this world together with the
serpent or Ophiomorphus. All this was done by the secret
contrivance of Sophia, whose object throughout was to win back the
light and return it to the highest world whence it had originally come.
Her manner of doing so seems to have been somewhat roundabout,
for it involved the further mingling of light with matter, and even
included the taking away by her of light from Adam and Eve when
turned out of Paradise and the restoring it to them when they
appeared on this earth—a proceeding which gave them to
understand that they had become clothed with material bodies in
which their stay would be only temporary[187]. Cain’s murder of Abel
was brought about by the same agency, as was the begettal of Seth,
ancestor of the existing human race. We further learn that the
serpent who was cast down got under him the angels begotten upon
Eve by the planetary powers, and brought into existence six sons
who, with himself, form “the seven earthly demons.” These are the
adversaries of mankind, because it was on account of man that their
father was cast down; and “this serpent is called Michael and
Sammael[188].” Later Ialdabaoth sent the Flood, sought out Abraham,
and gave the Law to the Jews. In this, as in everything, he was
opposed by his mother Sophia, who saved Noah, made the Prophets
prophesy of Christ, and even arranged that John the Baptist and
Jesus should be born, the one from Elizabeth and the other from the
Virgin Mary[189]. In all this, it is difficult not to see a later interpolation
introduced for the purpose of incorporating with the teaching of the
earlier Ophites the Biblical narrative, of which they were perhaps
only fully informed through Apostolic teaching[190]. It is quite possible
that this interpolation may be taken from the doctrine of the Sethians,
which Irenaeus expressly couples in this chapter with that of the
Ophites, and which, as given by Hippolytus, contains many Jewish
but no Christian features[191]. Many of the stories in this interpolation
seem to have found their way into the Talmud and the later Cabala,
as well as into some of the Manichaean books.
So far, then, the Ophites succeeded in accounting to their
satisfaction for the origin of all things, the nature of the Deity, the
origin of the universe, and for that of man’s body. But they still had to
account in detail for the existence of the soul or incorporeal part of
man. Irenaeus, as we have seen, attributes it to Ophiomorphus, but
although this may have been the belief of the Ophites of his time, the
Naassenes assigned it a more complicated origin. They divided it, as
Hippolytus tells us, into three parts which were nevertheless one, no
doubt corresponding to the threefold division that we have before
seen running through all nature into angelic, psychic, and earthly[192].
The angelic part is brought by Christos, who is, as we have seen, the
angel or messenger of the triune Deity, into “the form of clay[193],” the
psychic we may suppose to be fashioned with the body by the
planetary powers, and the earthly is possibly thought to be the work
of the earthly demons hostile to man[194]. Of these last two parts,
however, we hear nothing directly, and their existence can only be
gathered from the difference here strongly insisted upon between
things “celestial earthly and infernal.” But the conveyance of the
angelic soul to the body Hippolytus’ Ophite writer illustrates by a bold
figure from what Homer in the Odyssey says concerning Hermes in
his character of psychopomp or leader of souls[195]. As to the soul or
animating principle of the world, Hippolytus tells us that the Ophites
did not seek information concerning it and its nature from the
Scriptures, where indeed they would have some difficulty in finding
any, but from the mystic rites alike of the Greeks and the
Barbarians[196]; and he takes us in turns through the mysteries of the
Syrian worshippers of Adonis, of the Phrygians, the Egyptian (or
rather Alexandrian) worshippers of Osiris, of the Cabiri of
Samothrace, and finally those celebrated at Eleusis, pointing out
many things which he considers as indicating the Ophites’ own
peculiar doctrine on this point[197]. That he considers the god
worshipped in all these different mysteries to be one and the same
divinity seems plain from a hymn which he quotes as a song of “the
great Mysteries,” and which the late Prof. Conington turned into
English verse[198]. So far as any sense can be read into an
explanation made doubly hard for us by our ignorance of what really
took place in the rites the Ophite writer describes, or of any clear
account of his own tenets, he seems to say that the many apparently
obscene and sensual scenes that he alludes to, cover the doctrine
that man’s soul is part of the universal soul diffused through Nature
and eventually to be freed from all material contact and united to the
Deity; whence it is only those who abstain from the practice of carnal
generation who can hope to be admitted to the highest heaven[199].
All this is illustrated by many quotations not only from the heathen
poets and philosophers, but also from the Pentateuch, the Psalms,
the Jewish Prophets, and from the Canonical Gospels and St Paul’s
Epistles.
The connection of such a system with orthodox Christianity seems at
first sight remote enough, but it must be remembered that Hippolytus
was not endeavouring to explain or record the Ophite beliefs as a
historian would have done, but to hold them up to ridicule and, as he
describes it, to “refute” them. Yet there can be no doubt that the
Ophites were Christians or followers of Christ who accepted without
question the Divine Mission of Jesus, and held that only through Him
could they attain salvation. The difference between them and the
orthodox in respect to this was that salvation was not, according to
them, offered freely to all, but was on the contrary a magical result
following automatically upon complete initiation and participation in
the Mysteries[200]. Texts like “Strait is the way and narrow is the gate
that leadeth into eternal life” and “Not every one that saith unto me
Lord, Lord, shall enter into the kingdom of heaven” were laid hold of
by them as showing that complete salvation was confined to a few
highly instructed persons, who had had the sense to acquire the
knowledge of the nature of the Deity and of the topography of the
heavenly places which underlay the ceremonies of the Mysteries.
Such an one, they said after his death would be born again not with
a fleshly but with a spiritual body and passing through the gate of
heaven would become a god[201]. It does not follow, however, that
those who did not obtain this perfect gnosis would be left, as in some
later creeds, to reprobation. The cry of “all things in heaven, on
earth, and below the earth[202]” that the discord of this world[203] might
be made to cease, which the Naassene author quoted by Hippolytus
daringly connects with the name of Pappas given by the Phrygians
to Sabazius or Dionysos, would one day be heard, and the
Apocatastasis or return of the world to the Deity would then take
place[204]. If we may judge from the later developments of the Ophite
teaching this was to be when the last spiritual man (πνευματικός) or
perfect Gnostic had been withdrawn from it. In the meantime those
less gifted would after death pass through the planetary worlds of
Ialdabaoth until they arrived at his heaven or sphere, and would then
be sent down to the earth to be reincarnated in other bodies.
Whether those who had attained some knowledge of the Divine
nature without arriving at perfect Gnosis would or would not be
rewarded with some sort of modified beatitude or opportunity of
better instruction is not distinctly stated, but it is probable that the
Ophites thought that they would[205]. For just as those who have been
admitted into the Lesser Mysteries at Eleusis ought to pause and
then be admitted into the “great and heavenly ones,” the progress of
the Ophite towards the Deity must be progressive. They who
participate in these heavenly mysteries, says the Naassene author,
receive greater destinies than the others[206].
It might seem, therefore, that the Mysteries or secret rites of the
heathens contained in themselves all that was necessary for
redemption, and this was probably the Ophite view so far as the
return of the universe to the bosom of the Deity and the consequent
wiping out of the consequences of the unfortunate fall of Sophia or
Prunicos were concerned. A tradition. preserved by Irenaeus says
that Sophia herself “when she had received a desire for the light
above her, laid down the body she had received from matter—which
was, as we have seen, the visible heaven—-and was freed from
it[207].” But this seems to be an addition which is not found in the
Greek version, and is probably taken from some later developments
of the Ophite creed. It is plain, however, that the whole scheme of
nature as set forth in the opinions summarized above is represented
as contrived for the winning-back of the light—for which we may, if
we like, read life—from matter, and this is represented as the work of
Sophia herself. The futile attempt of the arrogant and jealous
Ialdabaoth to prolong his rule by the successive creation of world
after world, of the archetypal or rather protoplasmic Adam, and
finally of Eve, whereby the light is dispersed through matter more
thoroughly but in ever-diminishing portions[208], is turned against him
by his mother Sophia, the beneficent ruler of the planetary worlds,
who even converts acquaintance with the “carnal generation” which
he has invented into a necessary preparation for the higher
mysteries[209]. Thus Hippolytus tells us that the Naassenes
The generic law of the Whole was the first Intelligence of all
The second [creation?] was the poured-forth Chaos of the
First-born
And the third and labouring soul obtains the law as her
portion
Wherefore clothed in watery form [Behold]
The loved one subject to toil [and] death
Now, having lordship, she beholds the Light
Then cast forth to piteous state, she weeps.
Now she weeps and now rejoices
Now she weeps and now is judged
Now she is judged and now is dying
Now no outlet is found, the unhappy one
Into the labyrinth of woes has wandered.
But Jesus said: Father, behold!
A strife of woes upon earth
From thy spirit has fallen
But he [i.e. man?] seeks to fly the malignant chaos
And knows not how to break it up.
For his sake, send me, O Father;
Having the seals, I will go down
Through entire aeons I will pass,
All mysteries I will open
And the forms of the gods I will display,
The secrets of the holy Way
Called knowledge [Gnosis], I will hand down.
To Sabaoth:
To Astaphaios:
To Ailoaios:
and to Horaios:
Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.
testbankfan.com