Python

Python

Operating System has 10 Questions
What does os.name contain?

the name of the operating system dependent module imported
the address of the module os
error, it should've been os.name()
none of the mentioned
What does print(os.geteuid()) print?

the group id of the current process
the user id of the current process
both the group id and the user of the current process
none of the mentioned
What does os.getlogin() return?

name of the current user logged in
name of the superuser
gets a form to login as a different user
all of the above
What does os.close(f) do?

terminate the process f
terminate the process f if f is not responding
close the file descriptor f
return an integer telling how close the file pointer is to the end of file
What does os.fchmod(fd, mode) do?

change permission bits of the file
change permission bits of the directory
change permission bits of either the file or the directory
none of the mentioned
Which of the following functions can be used to read data from a file using a file descriptor?

os.reader()
os.read()
os.quick_read()
os.scan()
Which of the following returns a string that represents the present working directory?

os.getcwd()
os.cwd()
os.getpwd()
os.pwd()
What does os.link() do?

create a symbolic link
create a hard link
create a soft link
none of the mentioned
Which of the following can be used to create a directory?

os.mkdir()
os.creat_dir()
os.create_dir()
os.make_dir()
Which of the following can be used to create a symbolic link?

os.symlink()
os.symb_link()
os.symblin()
os.ln()