Answer:
f = open('students.txt', 'r')
Explanation:
In the computing world, a command is an instruction to a computer program to execute a particular task. These instructions might be issued via a command-line interface, such as a shell program, or as a input to a network service as a component of a network protocol, or can be instructed as an event in a graphical user interface activated by the respective user selecting an option in a menu.
the f = open('students.txt', 'r') command line would be used to open a file named "students.txt", There are also various other types of commands for executing different task, for example:
1. ASSOC for Fix File Associations
2. FC for File Compare
3. IPCONFIG for IP Configuration
4. NETSTAT for Network Statistics
5. PING for Send Test Packets
6. TRACERT for Trace Route
7. POWERCFG for Power Configuration
e.t.c.
Answer:
Email etiquette refers to the principles of behavior that one should use when writing or answering email messages. It is also known as the code of conduct for email communication. Email etiquette depends upon to whom we are writing- Friends & Relatives, Partners, Customers, Superior or Subordinates
Difference Between Etiquette and Netiquette is that Etiquette is the simple requirements needs for social behavior while Netiquette, is the code of acceptable behaviors users should follow while on the Internet.
Answer:
def func1(x):
return (x-32)*(5/9)
def func2(x):
return (x/2.237)
def main():
x = ""
while x != "x":
choice = input("Enter 1 to convert Fahrenheit temperature to Celsius\n"
"Enter 2 to convert speed from miles per hour to meters per second: ")
if choice == "1":
temp = input("please enter temperature in farenheit: ")
print(func1(float(temp))," degrees celcius.")
elif choice == "2":
speed = input("please enter speed in miles per hour: ")
print(func2(float(speed))," meters per second")
else:
print("error... enter value again...")
x = input("enter x to exit, y to continue")
if __name__ == "__main__":
main()
Explanation:
two function are defines func1 for converting temperature from ferenheit to celcius and func2 to convert speed from miles per hour to meters per second.
Answer:
Using Merge Sort.
Explanation:
Merge Sort is preferred for sorting the linked list because the the data stored in linked list is not in serial memory address which makes the quick sort algorithm very slow and other sorting algorithms impossible.
Merge Sort is a divide and conquer algorithm.
In this algorithms we divide the linked list into sub parts and sort the sub parts of the linked list and then we merge them in sorted order. It is a very effective approach for linked list sorting.
The time complexity of merge sort is O(NLogN).