I believe the answer is C) <span>servers are used directly by computers, not by people
Have a good day! =)</span>
Answer:
- class AirConditioner:
- def __init__(self, a_c=False):
- self.office_a_c = a_c
-
-
- ac = AirConditioner()
- ac.office_a_c = True
Explanation:
Firstly, create a class and name it as AirConditioner (Line 1).
Next in the class constructor, create the reference variable office_a_c (Line 3). Please note the reference variable shall be preceded with a self keyword. Besides, the reference variable is set to False by default.
Create an AirConditioner object (Line 6) and then use the dot syntax (.) to set the object reference variable office_a_c to True.
Answer:
The solution code is written in Python 3
- firstStr = input("Enter first string: ")
- secondStr = input("Enter second string: ")
-
- if(firstStr < secondStr):
- print("The first string comes first alphabetically.")
- elif(firstStr > secondStr):
- print("The second string comes first alphabetically.")
- else:
- print("The first and second string are same")
Explanation:
Firstly, prompt the user to input two strings (Line 1 - 2).
Next create if else if statement to check if the firstStr is less than, greater than or equal to the secondStr and then print the appropriate message accordingly (Line 4- 9). For example, the program display message "The first string comes first alphabetically." if it find the firstStr is less than secondStr.
Citation , hoped that helped