• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 3 out of 20 pages
Exam (elaborations)

Python Exam UAH Latest Update Actual Exam from Credible Sources with 250 Questions and Verified Correct Answers Golden Ticket to Guaranteed A+ Verified by Professor

Document preview thumbnail
Preview 3 out of 20 pages

Python Exam UAH Latest Update Actual Exam from Credible Sources with 250 Questions and Verified Correct Answers Golden Ticket to Guaranteed A+ Verified by Professor

Content preview

Python Exam UAH Latest Update 2024-2025
Actual Exam from Credible Sources with 250
Questions and Verified Correct Answers Golden
Ticket to Guaranteed A+ Verified by Professor
___represents an entity in the real world with its identity and behavior. - CORRECT
ANSWER:


(range(6)) - CORRECT ANSWER: (1,2,3,4,5,6)


A group of consecutive statements with the same indentation is called a _________ . -
CORRECT ANSWER: block


def value(a,b): return a[:b]. What is: print(value("Notebook",5)? - CORRECT ANSWER:


For x = (2+2)-(3*9)*(1-1)/12 - CORRECT ANSWER: 4


How are empty strings assigned in Python? - CORRECT ANSWER: "" var, str


How are the items in a dictionary deleted? - CORRECT ANSWER: del
dictionary_name[key]


How do you check the type of variable ? - CORRECT ANSWER:


How do you do an exponent in Python? - CORRECT ANSWER: x**n


How do you end an infinite loop on windows? - CORRECT ANSWER:


How do you output a blank line - CORRECT ANSWER: print()

,How do you print the second item in the list variable 'example'? - CORRECT ANSWER:
print (item 1)


How do you replace all "a" in a string "example" with "b"? - CORRECT ANSWER:


How does python do trig? - CORRECT ANSWER:


How does range(1,6) evaluate in Python? - CORRECT ANSWER: 1,2,3,4,5


How does range(2,10,2) evaluate in Python? - CORRECT ANSWER: 2,4,6,8,10


How does range(5, 0,-1) evaluate in Python? - CORRECT ANSWER: 5,4,3,2,1


How does range(5) evaluate in Python? - CORRECT ANSWER: 0,1,2,3,4,5


How is a dictionary defined? - CORRECT ANSWER: dict.


How many arguments can be passed to a function in a single function call? - CORRECT
ANSWER: zero or more


How to add x and y if x is an integer type, and y is a string ? - CORRECT ANSWER:


How would you add an alternate condition to an if statement? - CORRECT ANSWER:
else


How would you call the square root from the math module? - CORRECT ANSWER:
import math.sqrt


How would you cast the variable a that is equal to "2" to an integer 2? - CORRECT
ANSWER:

, If my_variable = "food", what is the data type of my_variable? - CORRECT ANSWER:


In Python, the operator != does what ? - CORRECT ANSWER: inequality


In Python, what data type do comparisons generate? - CORRECT ANSWER:


In Python, what is one function to output content to the display? - CORRECT ANSWER:


In Python, what is used to structure code? - CORRECT ANSWER:


In Python,the expression 4+3^2-6/3 will output - CORRECT ANSWER: syntax error (but
if 3**2 = 11)


inventory =["staff","hat","robe","bread"]. What is inventory.index("hat")? - CORRECT
ANSWER: 1


list movies= [["The Holy Grail",1975],["Sting", 1973]]. What is movies[1][0]? - CORRECT
ANSWER: sting


Math module is imported as m. What is: m.ceil(2.0083) ? - CORRECT ANSWER: 3


Math module is imported as m. What is: m.ceil(2.0083*10)/10? - CORRECT ANSWER:
2.1


Math module is imported as m. What is: m.ceil(2.0083*100)/100? - CORRECT
ANSWER: 2.01


num = set([1,1,2,3,3,3,4]) - CORRECT ANSWER:

Document information

Uploaded on
October 17, 2024
Number of pages
20
Written in
2024/2025
Type
Exam (elaborations)
Contains
Questions & answers
$20.99

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Tutordiligent
3.6
(96)
Sold
627
Followers
220
Items
8723
Last sold
1 day ago



Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions