Computers and Technology

Copy andpaste this into this linkhttps://www. programiz. com/python-programming/online-compi ler/ then answer the questions below. Will give brainliest if you do it correctly def myFunction():
a = int(input("Type in a number. "))
b = 1
for i in range(1, a + 1, 1):
b *= i
c = 0
for j in range(1, a + 1, 1):
c += j
d = 1
myTuple = (b , c)
return myTuple

x = myFunction()
print(x[0])
print(x[1])
print(x[-1])
print(x[-2])
tuple2 = 3 * x
print(tuple2)

1. What is the value of x[1] when the user types in 5?
2. What is the value of x[0] when the user types in 8?
3. What is the value of x[-1] when the user types in 4?
4. WHat is the value of tuple2[4] when the user types in 7?
5. Add a line that has tuple3 = x + tuple2. What is the value of tuple3[5] when the user types in 6?

answer
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 22:20, kaiyerecampbell95
Pp 4.1 design and implement a class called sphere that contains instance data that represents the sphere’s diameter. define the sphere constructor to accept and initialize the diameter and include getter and setter methods for the diameter. include methods that calculate and return the volume and surface area of the sphere (see pp 3.5 for the formulas). include a tostring method that returns a one-line description of the sphere. create a driver class called multisphere, whose main method instantiates and updates several sphere objects.
Answers: 1
image
Computers and Technology, 23.06.2019 15:00, med69
Barbara is interested in pursuing a career in the science and math pathway. which qualifications will her reach that goal? a. an advanced knowledge of physics and math b. an advanced knowledge of engineering and math c. an advanced knowledge of physics and robotics an d. advanced knowledge of machinery and math
Answers: 2
image
Computers and Technology, 23.06.2019 16:30, saintsfan2004
How to do this programming flowchart?
Answers: 3
image
Computers and Technology, 24.06.2019 07:20, djs1002
Ingrid started speaking about her slide presentation. when she clicked to th"third slide, which had just a picture of an elephant, she forgot what she wassupposed to talk about. what could ingrid do to avoid this situation in thefuture? oa. print handouts for her audience. ob. add presenter's notes to each slide. oc. add a video to each slide. od. save her slide presentation to a flash drive
Answers: 2
Do you know the correct answer?
Copy andpaste this into this linkhttps://www. programiz. com/python-programming/online-compi ler/ th...

Questions in other subjects: