1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
SCORPION-xisa [38]
4 years ago
12

Write a Python program to do the following:

Computers and Technology
1 answer:
viktelen [127]4 years ago
5 0

Answer:

(b)Tb = Ta[:3]

(c)Tc = Ta[-3:]

(d)Td = Tb + Tc

Explanation:

In order to generate random number in python, we need to first import random() function from random module

This function will generate a float number between 0 and 1, to make it between 1 and 15, we add 1 to the multiplication between the random number and the range differences

(a)

from random import random()

L = []

for i in range(10):

    L.append(1 + round(random()*14))

Ta = tuple(L)

(b) To copy the first 3 elements of tuple Ta, we simply go from : to 3

Tb = Ta[:3]

(c) To copy the last 3 elements of tuple Ta, we simply go from -3 to :

Tc = Ta[-3:]

(d) To concatenate the 2 tuples, we simply add them up

Td = Tb + Tc

You might be interested in
What are two drawbacks of using netbook ? (Choose two)
nydimaria [60]

Answer:

D and C

Explanation:

I would say D and C because they don't have fast processors they normally only use Celerons. and normally they only have a 64GB internal SSD.

It's definitley not a because they are extremely portable and have amazing battery life

I don't think its B because they have small screens but you can also get them in bigger 14" variants which is normally the generic size.

5 0
3 years ago
Use a search engine and spot the sponsored results for safer internet day.
snow_tiger [21]
What’s the question?
4 0
3 years ago
PLS HELP ASAP ILL GIVE BRAINLKEST THANKS ITS FOR TODAY
ANTONII [103]
Do u have context for the question? Based off of my brain alone, I would eliminate good food as an answer. I’d assume the answer to the second question is code.
8 0
3 years ago
Once artwork is inserted into a placeholder, it can be moved around on a slide. True False
inn [45]

Answer:

The answer to this question is true.

Explanation:

The artwork is used on the PowerPoint for making the presentation more effective. The artwork is also known as Clip Art. In the Microsoft PowerPoint, the clip art is a collection of media files like image file, video file, an audio file, and an animation file. If our computer has an Internet connection, then we can add new clip art for free. If we use the artwork or clip art on slide So it can be moved around on the slide.

6 0
3 years ago
What is objective reporting?
stira [4]
Objective reporting is reporting that separates facts and opinion.
7 0
3 years ago
Other questions:
  • Observing users as they enter passwords or other personal information to a computer Auditing software often used to test compute
    6·1 answer
  • In excel, you cannot format an entire column at once. true or false
    7·1 answer
  • What are some of the academic benefits of a later start time that Jordan mentions​
    12·1 answer
  • Which of the following best supports the utilization of environmental engineers on a civil engineering hydraulic project?
    13·1 answer
  • Help please and thank you
    11·1 answer
  • ___ is a family of data formats that helps people automatically receive feeds anytime there are new postings to their favorite b
    14·1 answer
  • Hello can you please help with this if you want to thank you!
    15·2 answers
  • Is pseudocode obtained from Algorithm or is Algorithm obtained from pseudocode?
    8·1 answer
  • Define operating system?explain the types of operating system on the basis of use.​
    7·1 answer
  • The int function can convert floating-point values to integers, and it performs rounding up/down as needed.
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!