subject

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?

ansver
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 12:00, clevelandjaniya1
Which of these is a benefit of using objects in a powerpoint presentation? a. collaborators can create the external files while you create and edit the slide show. b. you can easily change the theme and design of the presentation. c. you can have older data in the source file while having up-to-date data in the presentation. d. collaborators can easily share the presentation.
Answers: 2
image
Computers and Technology, 24.06.2019 00:30, bsonicx
The best definition of an idiom is a. a word or phrase that describes a noun b. a word or phrase describing a verb c. a phrase containing figurative language in which the word expresses a different idea from its exact meaning d. a phrase that compares two unlike objects or ideas
Answers: 2
image
Computers and Technology, 24.06.2019 02:30, Esmail
Write the pseudo code for this problem based on what you learned from the video. the purpose is to design a modular program that asks the user to enter a distance in kilometers, and then converts that distance to miles. the conversion formula is as follows: miles = kilometers x 0.6214
Answers: 3
image
Computers and Technology, 24.06.2019 15:00, dummynate
Universal windows platform is designed for which windows 10 version?
Answers: 1
You know the right answer?
Copy andpaste this into this linkhttps://www. programiz. com/python-programming/online-compi ler/ th...

Questions in other subjects:

Konu
Geography, 27.10.2019 09:43