subject

Now the hard task! 1 Write a function that gives the users four random integers between 1 and 10 and ask them to enter the square number of them. If the user answers all of them correctly, congratulate them. Otherwise, show them the right answer
# Step e: Import numpy -- ALWAYS import all the Libraries you need at the beginning! import numpy as np #Step 1: Function creation -- refer to the Last Lab for the syntax of function creation # does our function take parameters? * Create your function here:|| #Step 2: Create an array of four random integers between 1 and 10 #Step 3: Print your numbers #Step 4: Prompt the user to enter four numbers, ONE AT A TIME. Use a Loop to store these four numbers in a new array # HINT 1: We could take all four numbers in through one Line, but to practice Loop, Let's do it the hard way # HINT 2: You can start by creating an empty array -- np. array([]), then appending to it one at a time # HINT 3: Remember, input() only returns STRINGS. You need to turn them into integers #Step 5: Now that you have the two arrays, you can compare them using array functions and decide whether the answers are correct # HINT 4: To compare two arrays, you can use array1 == array2 -- however, you have to use a variable to hold the result The resulted array is an array of Boolean values. To quickly check whether it contains true value, you wight want to use the all() or any function...

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 02:40
Respecting individual differencespre-test active2time remaining48: 47nina is exploring her gender identity and sexual orientationwhich best describes how the role of the media might influence nina during this time in her life? the media would her decide because television shows are always unbiased about gender issues and do notstereotypethe media could make things difficult for her because television sometimes portrays rigid ideas about gender roles.all forms of media will her decide because the media always portrays rigid ideas about gender roles.all forms of media will make things easy for her because the media always portrays open and fair ideas about gender roles.
Answers: 1
question
Computers and Technology, 23.06.2019 01:00
Complete the sentence about a presentation delivery method
Answers: 2
question
Computers and Technology, 23.06.2019 03:30
How can you repin an image on your pinterest pin board a. click on the "repin" button b. click on the "add pin" button c. click on the "upload a pin" button d. click on the "save pin" button.
Answers: 2
question
Computers and Technology, 24.06.2019 02:00
What is a loop? a. a collection of function definitions at the top of a program b. a line of code that defines a variable and assigns it a value c. a program that opens the turtle graphics window d. a block of code that repeats a specific number of times
Answers: 1
You know the right answer?
Now the hard task! 1 Write a function that gives the users four random integers between 1 and 10 an...
Questions
question
Mathematics, 28.12.2019 20:31
question
Social Studies, 28.12.2019 20:31
question
Mathematics, 28.12.2019 20:31
question
History, 28.12.2019 20:31