Answer:
Written in Python
import random
#randnum = str(random.randint(999, 9999))
tryagain = "Yes"
while tryagain == "Yes":
randnum = "1234"
trys = 1
guess = input("Guess: ")
count = 0
while not count == 4:
for i in range(0,4):
if randnum[i] == guess[i]:
count = count + 1
if not count == 4:
print("You match "+str(count))
guess = input("Guess: ")
trys = trys + 1
else:
print("Congratulations, you match at "+str(trys))
trys = 1
tryagain = input("Start? (Yes/No): ")
Explanation:
I've added the full source code as an attachment where I used comments as explanation
true false you cannot fill in a callout
terms that represents the achual speed used by device to transfer data
Answer:Mb/s
Explanation:
megabytes per second
For this project you will write a Java program that will run a simple math quiz. Your program will generate two random integers between 1 and 20 and then ask a series of math questions. Each question will be evaluated as to whether it is the right or wrong answer. In the end a final score should be reported for the user. (See below for how to generate random numbers).Following the instructions from Closed Lab 01, create a new folder named FunWithBranching and a new Java program in that folder named FunWithBranching.java for this assignment.Sample Ouptut This is a sample transcript of what your program should do. Values in the transcript in BOLD show the user inputs. So in this transcript the user inputs 33, Jeremy, 24, -16, 80 and 0 - the rest is output from the program.Enter a random number seed: 33Enter your name: JeremyHello Jeremy!Please answer the following questions:4 + 20 = 24Correct!4 - 20 = -16Correct!4 * 20 = 80Correct!4 / 20 = 0Correct!4 % 20 = 4Correct!You got 5 correct answers!That's 100.0%!Your code will behave differently based on the random number seed you use and the answers provided by the user. Here is a second possible execution of this code. As before, values in BOLD are provided by the user - in this case 54, Bob, 8, 32, 8 and 1 - the rest is the output of the program when you run it.Enter a random number seed: 54Enter your name: BobHello Bob!Please answer the following questions:20 + 12 = 8Wrong!The correct answer is: 3220 - 12 = 32Wrong!The correct answer is: 820 * 12 = 8Wrong!The correct answer is: 24020 / 12 = 1Correct!20 % 12 = 8Correct!You got 2 correct answers!That's 40.0%!
Answer:
Here is the JAVA program:
import java.util.Scanner; //to accept input from user
public class FunWithBranching { //class name
public static void main(String[] args) { //start of main function
Scanner input = new Scanner(System.in); //creates Scanner object
System.out.print("Enter your name: "); //prompts user to enter name
String userName = input.nextLine(); //stores the name
System.out.print("Welcome " + userName + "! Please answer the following questions:\n"); //prompts user to answer the questions
int randomOperand1 = (int)(20 * Math.random()) + 1; //generates random number for operand 1 (1-20)
int randomOperand2 = (int)(20 * Math.random()) + 1; //generates random number for operand 2 (1-20)
int randomAdd = randomOperand1 + randomOperand2; //performs addition of two random numbers and stores result in randomAdd
int randomMul = randomOperand1 * randomOperand2; //performs multiplication of two random numbers
int randomDiv = randomOperand1 / randomOperand2; //performs division of two random numbers
int randomMod = randomOperand1 % randomOperand2; //performs modulo of two random numbers
int correctAns = 0; //stores number of correct answers
System.out.print(randomOperand1 + " + " + randomOperand2 + " = "); //displays random number + random number
int AdditionGuess = input.nextInt(); //reads the answer of addition from user and stores it in AdditionGuess
if (AdditionGuess == randomOperand1 + randomOperand2) { //if the user answer is correct
System.out.println("Correct!"); //displays correct
correctAns++; //adds 1 to the count of correctAns every time the user gives correct answer of addition
} else { //if user answer is incorrect
System.out.println("Wrong!"); //displays wrong
System.out.println("The correct answer is " + randomAdd); } //displays the correct answer of addition
System.out.print(randomOperand1 + " * " + randomOperand2 + " = "); //displays random number * random number
int MultiplicationGuess = input.nextInt(); //reads the answer of multiplication from user and stores it in MultiplicationGuess
if (MultiplicationGuess == randomOperand1 * randomOperand2) { //if the user answer is correct
System.out.println("Correct!"); //displays correct
correctAns++; //adds 1 to the count of correctAns every time the user gives correct answer of multiplication
}else{ //if user answer is incorrect
System.out.println("Wrong!"); //displays wrong
System.out.println("The correct answer is " + randomMul); } //displays the correct answer of multiplication
System.out.print(randomOperand1 + " / " + randomOperand2 + " = "); //displays random number / random number
int DivisionGuess = input.nextInt(); //reads the answer of division from user and stores it in DivisionGuess
if (DivisionGuess == randomOperand1 / randomOperand2) { //if the user answer is correct
System.out.println("Correct!"); //displays correct
correctAns++; //adds 1 to the count of correctAns every time the user gives correct answer of division
}else{ //if user answer is incorrect
System.out.println("Wrong!"); //displays wrong
System.out.println("The correct answer is " + randomDiv); } //displays the correct answer of division
System.out.print(randomOperand1 + " % " + randomOperand2 + " = "); //displays random number % random number
int ModGuess = input.nextInt(); //reads the answer of modulo from user and stores it in ModGuess
if (ModGuess == randomOperand1 % randomOperand2) { //if the user answer is correct
System.out.println("Correct!"); //displays correct
correctAns++; //adds 1 to the count of correctAns every time the user gives correct answer of modulo
}else{ //if user answer is incorrect
System.out.println("Wrong!"); //displays wrong
System.out.println("The correct answer is " + randomMod); } //displays the correct answer of modulo
double percentage = correctAns * 25; //computes percentage
System.out.println("You got " + correctAns + " correct answers."); //display number of correct answers given by user
System.out.println("That's " + percentage + "%!"); } } //displays percentage
Explanation:
The program is well explained in the comments mentioned with each line of code. The screenshot of the output is attached.
does my mum love me? I need to know...
Answer:
it depends she might need her space and yell at you get out my life it ok then. you just tell her to go to hell.
Explanation:
hope this helps!!
What are three steps to use to research relevant information on the internet? (Site 1)
Answer:
Step 1: Questioning --- Before going on the Internet, students should structure their questions. Step 2: Planning --- Students should develop a search strategy with a list of sites to investigate. Step 3: Gathering --- Students use the Web to collect and gather information.
Explanation:
there i did it for you can I get brainlyest
Answer:
Step 1: Questioning --- Before going on the Internet, students should structure their questions. Step 2: Planning --- Students should develop a search strategy with a list of sites to investigate. Step 3: Gathering --- Students use the Web to collect and gather information.
Explanation:
Cyberbullying prevention provides a safe environment by
stopping people from being bullies online.
showing people how to spot bullies online,
O rewarding people for catching bullies online,
O teaching people to ignore bullies online,
Answer:
stopping people from being bullies online.
Explanation:
balance = 100
balance = ((1.05) * balance) + 100
balance = ((1.05) * balance) + 100
balance *= 1.05
print(round(balance, 2))
Answer:
huh?
Explanation:
Are the actions legal or illegal?
a. Your company is moving toward final agreement on a contract in Pakistan to sell farm equipment. As the contract is prepared, officials ask that a large amount be included to enable the government to update its agriculture research. The extra amount is to be paid in cash to the three officials you have worked with. Should your company pay?
Answer:
No, Company will not pay
Explanation:
At the last point of the final deal, any significant sum of money does not fall into the frame.
It was important to address the exact amount needed to update the research on agriculture. They might be asking for inflated amounts.
Multiple Choice
Which discipline would you study to help a company have better tech support?
O information systems
O information technology
O computer engineering
O computer science
Answer:
information technology
Explanation:
correct on edge
The education discipline that helps in providing a company with technological support has been information technology. Thus, option B is correct.
What is tech support?Tech support has been the acronym for technological support. A company has been requiring the backend support that helps in resolving the issues related to the technical products.
The registered users can gain support for the products such as software, and the bugs can be resolved by the support team.
The support team has to deal with the problems related to the software and the technical bugs in the system that can be studied or solved with the knowledge of computer technology or information technology.
Thus, the discipline required for the tech support team is information technology. Hence, option B is correct.
Learn more about tech support, here:
https://brainly.com/question/21415070
#SPJ2
The K-Means algorithm terminates when:_______
a. a user-defined minimum value for the summation of squared error differences between instances and their corresponding cluster center is seen.
b. the cluster centers for the current iteration are identical to the cluster centers for the previous iteration.
c. the number of instances in each cluster for the current iteration is identical to the number of instances in each cluster of the previous iteration.
d. the number of clusters formed for the current iteration is identical to the number of clusters formed in the previous iteration.
Answer:
b. the cluster centers for the current iteration are identical to the cluster centers for the previous iteration.
Explanation:
K-mean algorithm is one of the mot widely used algorithm for partitioning into groups of k clusters. This is done by partitioning observations into clusters which are similar to each other. When using k-mean algorithm, each of the different clusters are represented by their centroid and each point are placed only in clusters in which the point is close to cluster centroid.
The K-Means algorithm terminates when the cluster centers for the current iteration are identical to the cluster centers for the previous iteration.
The K-Means algorithm terminates when:_
B. the cluster centers for the current iteration are identical to the cluster centers for the previous iteration.
According to the given question, we are asked to show when the K-Means algorithm terminates and the conditions which must be observed before this happens.
As a result of this, we can see that the K-mean algorithm has to do with dividing and organising k clusters of data which have similarities to each other and are denoted by a centroid.
With this in mind, we can see that the algorithm terminates when the cluster centers for the current iteration are identical to the cluster centers for the previous iteration.
Therefore, the correct answer is option B
Read more here:
https://brainly.com/question/15016224
What is the Web of Trust?
A. a group of experts who rate reviews as good or bad B. a group of experts who analyze reviews before they go online C. a group of reviewers who review products frequently D. a group of reviewers with your highest ratings
Answer:
A group of reviewers with your highest ratings
Answer:
D plato
Explanation:
Can I have some help debugging this exercise:// Application lists valid shipping codes// then prompts user for a code// Application accepts a shipping code// and determines if it is validimport java.util.*;public class DebugEight1{public static void main(String args[]){Scanner input = new Scanner(System.in);char userCode;String entry, message;boolean found = false;char[] okayCodes = {'A''C''T''H'};StringBuffer prompt = newStringBuffer("Enter shipping code for this delivery\nValid codes are: ");for(int x = 0; x < length; ++x){prompt.append(okayCodes[x]);if(x != (okayCodes.length - 1))prompt.append(", "); }System.out.println(prompt);entry = input.next();userCode = entry.charAt(0);for(int i = 0; i < length; ++i){if(userCode = okayCodes){found = true;}}if(found)message = "Good code";elsemessage = "Sorry code not found";System.out.println(message);}}
Answer:
See Explanation
Explanation:
The following lines of codes were corrected.
Note only lines with error are listed out
char[] okayCodes = {'A''C''T''H'};
corrected to
char[] okayCodes = {'A','C','T','H'};
StringBuffer prompt = newStringBuffer("Enter shipping code for this delivery\nValid codes are: ");
corrected to
StringBuffer prompt = new StringBuffer("Enter shipping code for this deliveryValid codes are: ");
for(int x = 0; x < length; ++x)
corrected to
for(int x = 0; x < okayCodes.length; ++x)
for(int i = 0; i < length; ++i)
corrected to
for(int i = 0; i < okayCodes.length; ++i)
if(userCode = okayCodes)
corrected to
if(userCode == okayCodes[i])
if(found)message = "Good code";elsemessage = "Sorry code not found";
corrected to
if(found)
message = "Good code";
else
message = "Sorry code not found";
However, I've added the full source code as an attachment
Create and test an HTML document that describes nested ordered lists of cars. The outer list must have three entries: compact, midsize, and sports. Inside each of these three lists there must be two sublists of body styles. The compact- and midsize-car sublists are two door and four door; the sports-car sublists are coupe and convertible. Each body-style sublist must have at least three entries, each of which is the make and model of a particular car that fits the category. The outer list must use uppercase Roman numerals, the middle lists must use uppercase letters, and the inner lists must use Arabic numerals. The background color for the compact-car list must be pink; for the midsize-car list, it must be blue; for the sports-car list, it must be red. All the styles must be in a document style sheet.1. Rewrite the document of Exercise 3.6 to put all style-sheet information in an external style sheet. Validate your external style sheet with the W3C CSS validation service.2. Rewrite the document of Exercise 3.6 to use inline style sheets only.3. Create and test an HTML document that contains at least five lines of text from a newspaper story. Every verb in the text must be green, every noun must be blue, and every preposition must be yellow.4. Create and test an HTML document that describes an unordered list of at least five popular books. The bullet for each book must be a small image of the book's cover. Find the images on the Web.
Answer:
ok so basically 3 x 9 is 278
Explanation:
ok so basically 3 x 9 is 278
a) What actions or steps in Excel can you take to rank them from 1st to 10th (4 marks)
b) State the specific action(s) or step(s) in Excel that will produce a list/display of those countries with 800 or more medals in total? (4 marks)
c) Which type of graph will be suitable for representing only gold medals information? (2 marks)
d) In which column(s) might replication have been used?
(2 marks)
e) What Excel formula can be used to calculate the overall total medals awarded? (3 marks)
14) Write the Excel functions for the following: (5 Marks each)
a. Give the total number of medals for Germany and Great Britain.
b. Give the average number of silver medals for a European country,
c. Sum the Medals Total for Gold for those countries with less than 20 games involvement.
d. Search the database (the whole spreadsheet) to find ‘Italy’ and also the corresponding Medals Total.
Answer:
a) highlight row F by clicking on F, go to toolbar at top undar DATA click filter, you will see an arrow next to F now, click the dropdown on the arrow and sort
Explanation:
Write a function swap that swaps the first and last elements of a list argument. Sample output with input: 'all,good,things,must,end,here'
Answer:
def swap(lst):
lst = lst.split(",");
temp = lst[0]
lst[0] = lst[-1]
lst[-1] = temp
return lst
lst = input("Enter the list items: ")
print(swap(lst))
Explanation:
Create a function named swap that takes one parameter, lst
Since the input is entered as commas between values, we need to split the values using split() function
Set the temp as the first item in the lst
Update the first item as the last item
Update the last item as temp (Note that temp has the initial value of the first item)
Return the list
Ask the user to enter the items
Call the swap function passing the input as parameter and print
Answer:
def swap (values_list):
values_list[0],values_list[-1]=values_list[-1],values_list[0]
return values_list
Explanation:
What is a browser?
software that enables individual computers to access Web sites on the World Wide Web through a graphical user interface
text that contains hyperlinks, which are connections to other data such as documents or web pages
a service that is available over the Internet
another term for web-based applications
Answer:
software that enables individual computers to access Web sites on the World Wide Web through a graphical user interface
Explanation:
Answer:
software that enables individual computers to access Web sites on the World Wide Web through a graphical user interface
Explanation:
Write an application that displays every perfect number from 1 through 1,000. A perfect number is one that equals the sum of all the numbers that divide evenly into it. For example, 6 is perfect because 1, 2, and 3 divide evenly into it, and their sum is 6; however, 12 is not a perfect number because 1, 2, 3, 4, and 6 divide evenly into it, and their sum is greater than 12.
Answer:
Written in Python
for num in range(1,1001):
sum=0
for j in range(1,num+1):
if num%j==0:
sum = sum + j
if num == sum:
print(str(num)+" is a perfect number")
Explanation:
This line gets the range from 1 to 1000
for num in range(1,1001):
This line initializes sum to 0 for each number 1 to 1000
sum=0
This line gets the divisor for each number 1 to 1000
for j in range(1,num+1):
This following if condition line checks for divisor of each number
if num%j==0:
sum = sum + j
The following if condition checks for perfect number
if num == sum:
print(str(num)+" is a perfect number")
5 seasons,10.episodes each from which episode in 1st season are 45 min and 35 sec, and in the remaining one are 35 mim and 15 sec each. Please help
Answer:
wow
Explanation:
Who could vote in the first democracy?
A.
Everyone
B.
Citizens
C.
Adults
D.
Women
Correct Answer: citizens
which of the following is an example of a technique used by a texture artist? A: Using multiple colors in a landscape B: Animating water to simulate rainfall C: Choosing hair color for a character D: Making concrete have a rough appearance
Answer:
A: Using multiple colors in a landscape I think
Explanation:
Answer:
I believe its D making concrete have rough appearances
Explanation:
color is not the texture artist job
A friend of yours is analyzing data collected on the response time to emergency calls. They are unsure about statis have asked for your advice:
Friend: I have got data on the response time to emergency calls for a random sample of 60 emergency responses. I've been asked to report some numbers to describe the center and spread of this data. Apparently there are several ways to do that and I am unsure which method I should use. I've looked at the data and it seems that the response times are fairly evenly spread around a time of 5 minutes. How should I best report the center and spread of this data?
You respond to your friend saying that, in this case, it is best to report the:____.
a. mean, minimum and maximum values.
b. median and interquartile range.
c. mean and standard deviation.
d. variance.
e. mode and range.
f. mean only.
Answer:
c. mean and standard deviation.
Explanation:
You respond to your friend saying that, in this case, it is best to report the mean and standard deviation. The mean will provide the best representation of the average based on the data that is provided. Meaning that response time that occurs the most often from all the data that was provided. While the standard deviation tells us, by how much the rest of the data is separated from the calculated average value.
Which part of this HTML tag is an "element"?
Hello World!
h1
A
оа
Ob
ос
Od
Hello World!
Answer:
h1
Explanation:
h1 is a heading tag
h1 has many types h 1-6
Answer:
I believe it is h1
Explanation:
Think about what your living room or bedroom will look like in 25 years. (One Paragraoh) Describe the technology and devices that will exist. Dream big, but be realistic. Who can guess the future?
Answer:
I think that there wont be much of a difference, other people might think there will be a big difference and get their hopes up. They will fail drastically multiple times. We will still be playing on our pcs at home or xbox. We will still have different varieties of xbox, video cards, ram, mother boards, and hard drives and all. Internet speeds will be through the roof.
Explanation:
Consider the following code segment.
for (int k = 0; k < 4; k++)
{
/* missing loop header */
{
System.out.print(k);
}
System.out.println();
}
The code segment is intended to produce the following output.
0
11
222
3333
Which of the following can be used to replace /* missing loop header */ so that the code segment will work as intended?
a. for (int h = 0; h < k; h++)
b. for (int h = 1; h < k + 1; h++)
c. for (int h = 0; h < 3; h++)
d. for (int h = k; h >= 0; h--)
e. for (int h = k; h <= 0; h--)
Answer:
for (int h = k; h >= 0; h--)
Explanation:
From the list of given options, option C answers the question.
In the outer loop
Initially, k = 0
In the inner loop,
h = k = 0
The value of h will be printed once because h>=0 means 0>=0 and this implies once
To the outer loop
k = 1
The inner loop will always assume value of k;
So,
h = 1
This will be printed twice because of the condition h>=0 means 1>=0.
Since 1 and 0 are >=0; 1 will be printed twice
To the outer loop
k = 2
The inner loop
h = 2
This will be printed thrice because of the condition h>=0 means 2>=0.
Since 2, 1 and 0 are >=0; 2 will be printed thrice
To the outer loop
k = 3
The inner loop
h = 3
This will be printed four times because of the condition h>=0 means 3>=0.
Since 3, 2, 1 and 0 are >=0; 3 will be printed four times
John needs to create a presentation on programming languages. He begins with the earliest developed language. Which programming language
does John begin with?
A. machine language
B. assembly language
C. C++
D. Visual Basic
Answer:
Of the given choices, Assembly.
Explanation:
Assembly was one of the first fully flushed programming languages, built on paradigms built throughout the late 40's and early 50's.
FORTRAN however was the first programming language with a compiler.
We may think of relationships in the E/R model as having keys, just as entity sets do. Let R be a relationship among the entity sets E1, E2, …,En. Then a key for R is a set K of attributes chosen from the attributes of E1, E2,…, En such that if (e1,e2,…,en) and (f1,f2,…,fn) are two different tuples in the relationship set for R, then it is not possible that these tuples agree in all the attributes of K. Now, suppose n=2; that is, R is a binary relationship. Also, for each I, let Ki be a set of attributes that is a key for entity set Ei. In terms of E1 and E2, give a smallest possible key for R under the assumption that:_________.1. R is many-many
2. R is many-one from E1 to E2.
3. R is many-one from E2 to E1.
4. R is one-one.
Explanation:
1
R is many - many;
in this case we have that E1 is not what should be used to determine E2 and in this same way, W2 is not what should determine E1. So non of these can be a key on its own.
2.
R is many-one from E1 to E2
in this case there are 2 tuples (f1,f2) and (e1,e2) which have to be the same if they have the same key attribute for E1. All of them are the same so all the pairs are the same.
3.
R is many-one from E2 to E1:
the explanation for this is is almost the same with that of b. we apply the same logic. since for all keys, all pairs and sets are the same.
4.
R is one-one:
E1 is what determines E2 and likewise, E2 is what determines E1. irrespective of the key that is used, key K is going to the same value of n.
New trends and tools are continuously emerging in the field of digital media. Discuss the advantages of these trends and tools for a digital media professional.
Answer:
There are multiple ways of being recognized and known, if new trends are emerging, people will try and get the most out of it so they can be recognized. Another reason is that people can try new things, it could be a new hobby, a new liking or just something they might want to share meaning it gets more attention
Explanation:
Making a Type I error means: _________.
a. We do not find enough evidence that there`s a difference in TV habits by gender for the class, when actually there is a difference.
b. We find evidence that there`s a difference in TV habits by gender for the class. There is a difference in TV habits by gender.
c. We do not find enough evidence that there`s a difference in TV habits by gender for the class.
d. We find evidence that there`s a difference in TV habits by gender for the class, when there is actually no difference. There is no difference in TV habits by gender.
Answer:
d.
Explanation:
Making a Type I error means we find evidence that there`s a difference in TV habits by gender for the class when there is actually no difference. There is no difference in TV habits by gender. Type 1 errors are usually seen in statistical hypothesis testing and refer to accepting a conclusion that only occurred due to lucky circumstances but are not factually correct and will likely not happen again, the same applies for the opposite where a conclusion is rejected due to an unlikely circumstance when in actuality it is a correct conclusion.
Define an average function that takes 4 arguments, calculates the average of the 4 numbers passed to it, and returns the result back to the caller. Capture the 4 values from the user in main() and pass them to the function average. Call the average function from main. Print the results returned in the main function. Call the average function three more times with three more sets of four numbers and return the results back to the caller. Save the return values in variables in main(). Pass all four return values saved in main() back to the average function as arguments to calculate the average of the averages and return the result to main() which will print the final result ( average of the averages).
Answer:
ok so basically 3 x 9 is 278
Explanation:
ok so basically 3 x 9 is 278
A colon after a word in a search engine entry indicates:
A.the word is a command with a specific function.
B.the word should be excluded from the search.
C.the word MUST be included in all search results.
D.which type of logic system the search engine should use.
Answer:
The answer is A)
Explanation:
I got it right when i took the test.
A colon after a word in a search engine entry b: The word is a command with a specific function. Hence, option A is correct.
What is colon after a word?A colon is a punctuation mark that can be used to emphasize, indicate composition titles, start text lists, and start a sentence. Emphasis: Only a proper noun or the start of a full sentence should come before the first word following the colon. She had fallen head over heels for Western Michigan University.
A whole sentence almost always precedes a colon; the text that follows the colon may or may not be a simple list, another entire sentence, or even just a single word. Although it tends to be preferred in American language, a capital letter usually follows a colon in British usage.
Thus, option A is correct.
For more information about colon after a word, click here:
https://brainly.com/question/1246927
#SPJ5