













Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
A set of questions and answers related to python and java programming languages, designed to help developers prepare for certification exams. It covers a range of topics, including data types, control structures, object-oriented programming concepts, and exception handling. Each question is followed by a rationale, offering a deeper understanding of the correct answer. This resource is valuable for students and professionals looking to enhance their knowledge and skills in python and java development, and to successfully pass certification exams. The questions are designed to test understanding of fundamental concepts and best practices in both languages, making it a useful tool for self-assessment and exam preparation.
Typology: Exams
1 / 21
This page cannot be seen from the preview
Don't miss anything!














b) Removes leading and trailing whitespace from a string c) Removes all whitespace in the string d) Converts string to uppercase Answer: b Rationale: strip() removes only leading and trailing whitespace, not internal spaces.
Answer: b Rationale: Using *args allows the function to take a variable number of positional arguments.
c) dict = () d) dict = set() Answer: a Rationale: Curly braces {} are used to define dictionaries.
d) num("123") Answer: a Rationale: int() converts a numeric string to an integer.
Answer: a Rationale: y = x[:] creates a copy; modifying y does not affect x.
Answer: a Rationale: Sets automatically remove duplicate elements.