Create a list that has four elements. Make a copy of the list and change one of the elements in the copy. Show that the same element in the original list did not change.

What will be an ideal response?


>>> num = [1, 2, 3, 4]
>>> num_copy = num[:]
>>> num_copy[0] = 9999
>>> num
[1, 2, 3, 4]
>>> num_copy
[9999, 2, 3, 4]

Computer Science & Information Technology

You might also like to view...

What feature of NTFS allows a file or folder to point to another file or folder located somewhere else in the file system?

A. volume mount points B. symbolic links C. alternate data streams D. transactional NTFS

Computer Science & Information Technology

Which of the following would be TRUE of the Bcc: box in an e-mail header?

A) Bcc is an option available only with standalone packages such as Outlook. B) Bcc is an option available only with Web-based e-mail. C) The primary recipient will not see the address of anyone copied using this line. D) Bcc is available in all e-mail packages today.

Computer Science & Information Technology

Unlike automatic variables that can be initialized by either constants or expressions using both constants and previously initialized variables, static variables can only be initialized using constants or constant expressions.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

For security applications, the biometric system should be calibrated to produce a FAR less than or equal to ___________ percent.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology