admin Oct, Wed, 2024 EXAM PYTHON FULL STACK 123456789101112131415161718192021222324252627282930313233343536373839404142434445 Exam Instructions: Total Number of Questions: 45 You will be required to answer a total of 45 multiple-choice questions. Time Limit: 15 minutes for the entire exam Once the time is up, the exam will automatically submit. Passing Criteria: A minimum score of 50% is required to pass the exam Multiple Attempts: You are allowed to take the exam multiple times. Only your highest score will be considered for certification. Additional Instructions: The exam timer cannot be paused once it begins. Good luck, and feel free to retake the exam to improve your score! PYTHON FULL STACK Test your PYTHON FULL STACK skills with a challenging exam designed to evaluate your knowledge in programming, data structures, and algorithms The certificate will be generated based on the information you provide in the form, so please ensure that all details are entered correctly. NameEmailPhone NumberUniversityCollegeDegreeDepartmentPass Out YearPass Out Year2014201520162017201820192020202120222023202420252026202720282029 1 / 45 1) What is the output of print(“hello”.title())? A) Hello B) Hello C) Hello D) Hello 2 / 45 2) What does self refer to in a method? A) The method name B) The class itself C) The instance of the class D) The instance of the class 3 / 45 3) How do you remove duplicates from a list? A) list(set(my_list)) B) my_list.distinct() C) list(set(my_list)) D) my_list.remove_duplicates() 4 / 45 4) How do you check if a key exists in a dictionary? A) key.exists(dict) B) key in dict C) key in dict D) dict.has_key(key) 5 / 45 5) What will be the output of print(0 == False)? A) False B) 1 C) True D) True 6 / 45 6) How do you remove duplicates from a list? A) set(my_list) B) Both 1 and 2 C) Both 1 and 2 D) list(dict.fromkeys(my_list)) 7 / 45 7) How do you get the current working directory in Python? A) os.getcwd() B) os.current() C) getcwd() D) os.getcwd() 8 / 45 8) What keyword is used to define a module in Python? A) import B) import C) define D) module 9 / 45 9) How do you create a copy of a list? A) list.copy() B) list.copy() C) copy(list) D) list[:] 10 / 45 10) Which of the following is a Python web framework? A) Both B) Django C) Flask D) Both 11 / 45 11) How do you create a tuple in Python? A) my_tuple = {} B) my_tuple = [] C) my_tuple = () D) my_tuple = () 12 / 45 12) What will be the output of print((1, 2) + (3, 4))? A) (1, 2, 3, 4) B) Error C) (1, 2, 3, 4) D) (4, 3, 2, 1) 13 / 45 13) What is the output of print(“abc” * 3)? A) Error B) abcabcabc C) abcabc D) abcabcabc 14 / 45 14) What is the output of print(2 > 1 and 3 > 2)? A) True B) 1 C) False D) True 15 / 45 15) How do you access the last element of a list? A) list[-1] B) list[len(list)-1] C) list.last() D) list[-1] 16 / 45 16) How do you reverse a list in Python? A) Both 1 and 3 B) list.reverse() C) reversed(list) D) list[::-1] 17 / 45 17) How do you remove duplicates from a list? A) list.unique() B) set(list) C) set(list) D) list.remove_duplicates() 18 / 45 18) How do you write a comment in Python? A) # This is a comment B) /* This is a comment */ C) # This is a comment D) // This is a comment 19 / 45 19) How do you install a package using pip? A) pip get package_name B) pip install package_name C) install package_name D) pip install package_name 20 / 45 20) What is the output of print(“a” in “abc”)? A) True B) True C) False D) Error 21 / 45 21) How do you import a module in Python? A) import module_name B) import module_name C) include module_name D) using module_name 22 / 45 22) How do you get the index of an element in a list? A) my_list.find(element) B) my_list.get_index(element) C) my_list.index(element) D) my_list.index(element) 23 / 45 23) What does the sorted() function do? A) Returns a sorted list B) Returns a sorted list C) Sorts in place D) Returns the original list 24 / 45 24) What is the output of `print({1, 2} A) Tests knowledge of set union B) {1, 2, 3} C) True D) {1, 2} 25 / 45 25) What is the purpose of the self parameter in class methods? A) Refers to the instance of the class B) Refers to a module C) Refers to the class itself D) Refers to the instance of the class 26 / 45 26) How do you find the index of an element in a list? A) element.index(list) B) list.index(element) C) list.index(element) D) find(list, element) 27 / 45 27) What does the @staticmethod decorator do in a class? A) Defines a method for instance access B) Defines a method that doesn't access instance or class C) Defines a method for class access D) Defines a method that doesn't access instance or class 28 / 45 28) What is the output of print(len([1, 2, 3]))? A) 3 B) 1 C) 3 D) 2 29 / 45 29) What is the purpose of assert in Python? A) Prints a message B) Both 1 and 2 C) Raises an exception D) Checks a condition 30 / 45 30) What is the purpose of if __name__ == “__main__”:? A) Checks if the script is imported B) Checks if the script is run directly C) Both D) Both 31 / 45 31) Which decorator is used to create a static method in Python? A) @staticmethod B) @decorator C) @staticmethod D) @classmethod 32 / 45 32) What is the output of print(“hello world”.split())? A) ['hello', 'world'] B) hello world C) Error D) ['hello', 'world'] 33 / 45 33) How do you get the last element of a list? A) my_list[-1] B) my_list[-1] C) my_list.last() D) my_list.get(-1) 34 / 45 34) What does the join() method do? A) Reverses a string B) Combines a list into a string C) Splits a string into a list D) Combines a list into a string 35 / 45 35) What is the output of print(2 ** 3)? A) 8 B) 8 C) 9 D) 6 36 / 45 36) How do you create a class in Python? A) class MyClass: B) class = MyClass: C) def MyClass: D) class MyClass: 37 / 45 37) How do you create a list comprehension? A) list = [x, range(5)] B) [x for x in range(5)] C) list(x for x in range(5)) D) [x for x in range(5)] 38 / 45 38) Which of the following is a Python web framework? A) Laravel B) Flask C) Ruby on Rails D) Flask 39 / 45 39) How do you read a file line by line in Python? A) file.readlines() B) for line in file: C) for line in file: D) file.read() 40 / 45 40) How do you read a file in Python? A) open('file.txt').read() B) file.read('file.txt') C) read('file.txt') D) open('file.txt').read() 41 / 45 41) What is the purpose of a requirements.txt file? A) Lists project dependencies B) Lists project dependencies C) Defines project structure D) Contains project settings 42 / 45 42) How do you create a virtual environment in Python? A) env.create() B) virtualenv env C) python -m venv env D) python -m venv env 43 / 45 43) How do you create a new file in Python? A) create('file.txt') B) open('file.txt', 'w') C) open('file.txt', 'r') D) open('file.txt', 'w') 44 / 45 44) How can you install Django? A) pip install Django B) pip install Django C) django install D) install Django 45 / 45 45) Which of the following is a valid URL in Python? A) www.example.com B) http://www.example.com C) example.com D) http://www.example.com Your score is LinkedIn Facebook Twitter VKontakte 0% ExamWEB DEVELOPMENT EXAM...Read MoreREACT JS PROGRAMMING EXAM...Read MorePYTHON FULL STACK...Read MorePYTHON EXAMS ...Read MoreMYSQL...Read MoreMACHINE LEARNING...Read MoreJAVASCRIPT PROGRAMMING EXAM...Read MoreJAVA SPRING BOOT...Read MoreJAVA PROGRAMMING EXAM...Read MoreJAVA FULL STACK...Read MoreHTML PROGRAMMING EXAM...Read MoreDEEP LEARNING...Read MoreDATA SCIENCE...Read MoreCSS PROGRAMMING EXAM...Read MoreANGULAR JS PROGRAMMING EXAM...Read More 13Share on WhatsApp6Share on LinkedIn4Share on YouTube9Share on Facebook Comments 0