Question:- Which of the following statements is/are TRUE in respect of the Python programming language? Statement 1: Python is an interpreted, high-level, general-purpose programming language. Statement 2: Python provides high-level data structures along with dynamic binding and typing for Rapid Application Development and deployment. Statement 3: Python is a Statically typed Programming language. Options: Only Statement 1 Statement 1 and 2 Statement 1 and 3 All Statements are Correct
Answer:- Answer: B: Statement 1 and 2 Explanation: Python is an interpreted, high-level, general-purpose programming language. Being an interpreted language, it executes every block of code line by line, and thus type-checking is done while executing the code. Hence, it is a dynamically typed language. Moreover, Python offers high-level data structures, together with dynamic binding and typing, allows a large community of developers for Rapid Application Development and Deployment.
Question:- What is the full form of PEP? Options: Python Enhancement Proposal Python Enchantment Proposal Programming Enhancement Proposition Python Enrichment Program
Answer:- Answer: A: Python Enhancement Proposal Explanation: A PEP, also known as Python Enhancement Proposal, is an official design document offering information to the community of Python developers or depicting a new feature for Python or its methods.
Question:- Which of the following statements is/are NOT correct regarding Memory Management in Python? Statement 1: Python Memory Manager handles the management regarding memory in Python Statement 2: Python uses CMS (Concurrent Mark Sweep) approach as its Garbage Collection technique. Statement 3: Python offers a core garbage collection to recycle the vacant memory for the private heap space. Options: Only Statement 3 Statement 1 and 3 Statement 2 and 3 Only Statement 2
Answer:- Answer: D: Only Statement 2 Explanation: Python employs the Reference Counting algorithm as its Garbage Collection technique. This technique is highly efficient and straightforward; however, it cant detect the reference cycle. Hence, Python has an additional algorithm known as Generational Cyclic (GC), which only deals with the reference cycle.
Question:- Which of the following statements is/are NOT correct in respect to Python namespaces? Statement 1: Python implements the namespace in the form of Array. Statement 2: Python namespaces are classified into three types - local, global and built-in. Statement 3: A Python namespace ensures that the names of the objects in a program are unique and can be utilized, deprived of any inconsistency. Options: Only Statement 1 Only Statement 3 Statement 1 and 2 Statement 1 and 3
Answer:- Answer: A: Only Statement 1 Explanation: The namespaces in Python are implemented in the form of Dictionaries where key denotes the name, mapped to a corresponding value denoting the object.
Question:- Which of the following is invalid in terms of Variable Names? Options: _mystr = "Hello World!" __mystr = "Hello World!" __mystr__ = "Hello World!" None of the mentioned
Answer:- Answer: D: None of the mentioned Explanation: All Statements will be executed successfully. However, the code readability will also be reduced.
Question:- In respect to the scope in Python, which of the following statements is/are TRUE? Statement 1: A variable created within a function belongs to the local scope and can be used outside that function. Statement 2: A local scope is referred to the object present through the execution of code since its inception. Statement 3: A local scope is referred to the local object present in the current function. Options: Only Statement 2 Statement 1 and 3 Only Statement 3 All Statements are True
Answer:- Answer: C: Only Statement 3 Explanation: Local scope, also known as function scope, is the block of code or body of any function in Python. This scope consists of the names that we define within the function. These names will only be observable from the function code. It is created at the function call, not at the definition of the function, so that we will have as many distinct local scopes as the calls in function. This is true even when we call the same function more than one time or recursively. Every call will return a new local scope.
Question:- Among the following statements based on the difference between lists and tuples, which one statement is TRUE? Statement 1: List is a sequence data structure, whereas Tuple is not. Statement 2: Lists are immutable; however, Tuples are mutable. Statement 3: Tuple is a sequence data structure, whereas List is not. Statement 4: Tuples are immutable; however, Lists are mutable. Options: Statement 1 Statement 4 Statement 2 Statement 3
Answer:- Answer: B: Statement 4 Explanation: Apart from many similarities, one of the significant differences between the two is that the Lists are mutable, whereas Tuples are immutable. This statement implies that we can modify or change the values of a list; however, we cant alter the values of a Tuple.
Question:- What are Tags?
Answer:- HTML tags are composed of three things: an opening tag, content and ending tag. Some tags are unclosed tags. HTML documents contain two things: - content, and - tags When a web browser reads an HTML document, the browser reads it from top to bottom and left to right. HTML tags are used to create HTML documents and render their properties. Each HTML tags have different properties. Syntax: content Content is placed between tags to display data on the web page.
Question:- What is formatting in HTML?
Answer:- The HTML formatting is a process of format the text for a better look and feel. It uses different tags to make text bold, italicized, underlined.
Question:- The HTML contains six types of headings which are defined with the to
to tags. Each type of heading tag displays different text size from another. So, is the largest heading tag and is the smallest one. For example:
is the largest heading tag and is the smallest one. For example:
Answer:- The HTML contains six types of headings which are defined with the to
to tags. Each type of heading tag displays different text size from another. So, is the largest heading tag and is the smallest one. For example: Heading no. 1
, Heading no. 2
, Heading no. 3
, Heading no. 4
, Heading no. 5
, Heading no. 6
is the largest heading tag and is the smallest one. For example: Heading no. 1
, Heading no. 2
, Heading no. 3
, Heading no. 4
, Heading no. 5
, Heading no. 6
Heading no. 1
,Heading no. 2
,Heading no. 3
,Heading no. 4
,Heading no. 5
,Heading no. 6
Question:- How to create a hyperlink in HTML?
Answer:- The HTML provides an anchor tag to create a hyperlink that links one page to another page. These tags can appear in any of the following ways: Unvisited link - It is displayed, underlined and blue. Visited link - It is displayed, underlined and purple. Active link - It is displayed, underlined and red.
Question:- Which HTML tag is used to display the data in the tabular form?
Answer:- It defines a table.,
| It defines a header cell in a table., | It defines a cell in a table., |
|---|
