Q9:- Which data-type .maketrans() return? Table List Tuple Dictionary   Q 10:- How to loop over the float range? Arange Enumerate Range None of these Q4:- Which of the following is correct ? deafaultdict throws a KeyErrror when the key is not present in it.    Sorting dictionary by the key has more runtime accessing than the sorting by the value. c)Sorting dictionary by the key has less runtime accessing than the sorting by the value. d).None of these. Q5:- Choose the correct statement:- getattr() and setattr() are used to retrieve and set class attributes.   pow() and ** will always produce the same value. getattr() and setattr() are used to retrieve and set Constructor attribute. None of these.

Question

Q9:-

Which data-type .maketrans() return?

  1. Table
  2. List
  3. Tuple
  4. Dictionary  

Q 10:-

How to loop over the float range?

  1. Arange
  2. Enumerate
  3. Range
  4. None of these

Q4:-

Which of the following is correct ?

  1. deafaultdict throws a KeyErrror when the key is not present in it.
  2.    Sorting dictionary by the key has more runtime accessing than the sorting by the value.

c)Sorting dictionary by the key has less runtime accessing than the sorting by the value.

d).None of these.

Q5:-

Choose the correct statement:-

  1. getattr() and setattr() are used to retrieve and set class attributes.  
  2. pow() and ** will always produce the same value.
  3. getattr() and setattr() are used to retrieve and set Constructor attribute.
  4. None of these.

Expert Answer

Want to see the step-by-step answer?

Check out a sample Q&A here.

Want to see this answer and more?

Experts are waiting 24/7 to provide step-by-step solutions in as fast as 30 minutes!*

*Response times may vary by subject and question complexity. Median response time is 34 minutes for paid subscribers and may be longer for promotional offers.
Tagged in
Engineering
Computer Science

Related Computer Science Q&A

Find answers to questions asked by students like you.

Q: Problem: Create a base class called Vehicle that has the manufacturer’s name (type String), number o...

A: The java program and approach are given below:Approach: Defining the class “Vehicle” with required m...

Q: Create a class of students that should contain fields like rollno,name,subject and marks?

A: Programming language assumed is C++:Class:A C++ class is the building block, which contributes to th...

Q: I need to solve this in C++ code  When analyzing data sets, such as data for human heights or for hu...

A: A C++ program for the given criteria is as follows,//Declare header files#include <iostream>#i...

Q: In C++: First try to predict how many times will the following for loops execute?  What is the outpu...

A: Implementing the given program in a proper class to get the output://importing essential header file...

Q: Which type of cryptography provides the most security? Group of answer choices Digital signature cr...

A: Answer:Option D: Asymmetric cryptography

Q: For each subnet assign a private IP address (of the form a.b.c.d/y) such that:• The IP range is cont...

A: Part (A): Subnet NameAddress 110.5.73.32210.0.0.0310.4.0.0410.5.64.0510.5.73.0610.5.72.0710.5.0.0810...

Q: Order the following: O(n2), O(12 + 7n), O(n log(n) + 300 n2 + 1/125 n3)

A: Ordering based on Big-O notationAccording to Big-O notation, f (n) = O (g (n)) if there exist a posi...

Q: What is data granularity?

A: Data Granularity:In the field of computer science, granularity means, breaking down of larger tasks ...

Q: Write a C# program of a bubble short and validate the program with the help of a proper example.

A: Click to see the answer

Q: How is the software component of an information system is designed?

A: Information system:It is a set of subsystems used for achieving some objective.It accepts data as in...

Q: Write a very simple class definition in PHP.

A: Class:A class is a collection of objects with its own properties and behaviors.A programmer can defi...

Q: Please answer as soon as posibble.

A: The code given below is written in Python programming language.The output of the code is arg1: john,...

Q: Provide the code to create an input box for the country field with the default text "United States".

A: Code:<!DOCTYPE html><html><body>Country: <input name="country" value="United St...

Q: Write a C++ program You are burning some music CDs for a party. You've arranged a list of songs in t...

A: Following is the C++ program:Header file are declared.Main function is defined.Declare necessary var...

Q: I need help with the following Python 3 program: Given a distance (in kilometers) and a finish time ...

A: The below given python program will obey the following rubrics:Importing essential header files.Disp...

Q: Draw the logic diagram for the following Boolean expressions. The diagram should correspond exactly ...

A: OR gate is used where + is provided in the boolean expression.AND gate is used where .(or multiplica...

Q: 1. The document must have a paragraph of at least 10 lines of text that describe you. This paragraph...

A: Note: As per our honor code, we only answer a question at a time. Please post the second question ag...

Q: Using OOP language Java Given a currency with denominations of 100, 50, 20, 10, 5 and 1 write a meth...

A: Program DescriptionWe define a class called MakeChange which has a private static method called make...

Q: What are the differences between C and C++?

A: Difference between C and C++:

Q: Function decode(comm, null, 0, comm) is the same asA) NVL(comm, 0)B) decode(comm, comm, comm, 0)C) u...

A:  The function decode() work as if-then-else, the first argument is the expression or column which is...

Q: Odd even Challange Python Coding Tell user to input a 3 digital number ONLY Use a WHILE LOOP to ask ...

A: Following is the python program that takes as input from user a number and makes sure a number is a ...

Q: - Give everybody 10% salary increase in the departments whose maximum salaries are less than 2000

A: Create a table and name it as EMP.Syntax to create a table –CREATE TABLE table_name (    column1 dat...

Q: (1) Prompt the user for a title for data. Output the title. Ex: Enter a title for the data: Number o...

A: Answer 1:Source code#include <iostream>using namespace std;int main(){  string title;  cout&lt...

Q: The computer-aided software engineering (CASE) approach is often utilized in the system development ...

A: CASE stands for computer aided software engineering:It is used for designing and implementing applic...

Q: Draw the logic diagram for the following Boolean expressions. The diagram should correspond exactly ...

A: a)Logic diagram for the given Boolean expression is,

Q: Hi, I am programming in java. The instructions require: Create a new project and call it Project8. C...

A: All the changes are commented above the modified or added line.In main() method Mymethod() called an...

Q: Why is data encryption so important?

A: Encryption is a method of changing data in the way as to make it unclear by everyone except those po...

Q: What is the difference between hexanumber and ascii code

A: Warm-up description –ASCII code –ASCII stands for American Standard Code for Information Interchange...

Q: Express E and F in sum-of-minterms algebraic form.

A: A MinTerm is a product term of all the variables in a Boolean function in normal or complemented for...

Q: Define a Python function named adder to take two integer parameters and return their sum. Multiple l...

A: Python functionIn python, a function is a block of program statements which can be used repetitively...

Q: Write a short C++ program to read 3 integer numbers from the keyboard and display their average as a...

A: The below given C++ program will obey the following rubrics:Importing essential header files.Declari...

Q: Write a function prototype for a function named my_function that accepts two integers (a,b) as param...

A: Program:#include <iostream>using namespace std; int my_function(int a, int b){  int s = a + b;...

Q: How would merging mobile central office functions and landline central office function into CORD dat...

A: Central office functions:Landline central office functions route the calls between the providers, co...

Q: 3.35. Input an integer ( 5 digits or less ) containing only 1's and 0's and print its decimal equiva...

A: A C program to print the decimal equivalent of binary integer is as follows,File name: “main.c”#incl...

Q: The local Driver's License Office has asked you to writea program that grades the written portion of...

A: The below given java program will obey the following rubrics:Importing essential header files.Declar...

Q: To be done in C++   Brief Description: This program will ask the user to enter details about a class...

A: Program instructions:Declare the structure of the ‘student’ type.Then, create an array of student ty...

Q: What is the Big Oh runtime for the following function in terms of n? Show your work.   int recurse(i...

A: Big Oh runtime:Now, the condition if(n==0) makes a comparison and if n = 0, the value 1 is returned....

Q: JavaScript Project     Create a guessing game program.   Prompt the user to guess a random number (M...

A: Save this program to game.html.Double click on html file to open it in browser.

Q: Draw the logic diagram for the following Boolean expressions. The diagram should correspond exactly ...

A: a)Logic diagram for the given Boolean expression is,

Q: Write one Python statement to start and continue a while loop while variable name is not an empty st...

A: While loop:With the while loop, if a condition is valid, we may execute a series of statements.Synta...

Q: Explain various types of polymorphism?State differences between them?

A: Polymorphism:Polymorphism is an important feature of object-oriented programming languages.It refers...

Q: In Python 3.7: A fuel-economy study was carried out for five models of cars. Each car was driven 100...

A: Python program is given to calculate average miles per gallon in decreasing order with respect to mi...

Q: Did I correctly perform the SQL query below (photo attached): A query that contains the GROUP BY cla...

A: Answer:“Yes”, the given query is correct.

Q: Write a program in python w/ no imports that the owner of Chica Chic could use to store data about h...

A: Open a file called inventory.txtThe file inventory.txt has the name of an inventory, cost, and quant...

Q: Using Java Implement a class that does string manipulation by overloading the following operators: &...

A: The question expects that the operators be overloaded using Java programming language. However, Java...

Q: I need help with the following Python 3 question:   Write a Python program that, for a given amount ...

A: The below given python program will obey the following rubrics:Defining main method.Displaying messa...

Q: Which of the following detects unauthorized user activities, attacks, and network compromises and en...

A: System that detects unauthorized user activities and prevents breaches from occuringIntrusion Detect...

Q: In C++: If the keyboard input is: A B D, what is the output for the following program and why? (ASCI...

A: Source Code#include <iostream>using namespace std;main(){char x, y, z;cin >> x >> ...

Q: First, launch NetBeans and close any previous projects that may be open (at the top menu go to File ...

A: Following is the source code according to the requirements given in the question. Comments have been...