Write a program that simulates a fishing game. In this game, a six-sided die is rolled to determine what the user has caught. Each possible item is worth a certain number of fishing points. The points will remain hidden until the user is finished fishing, and then a message is displayed congratulating the user depending on the number of fishing points gained.

Answers

Answer 1

Answer:

Answered below

Explanation:

//Python code

numberOfCasts = 3

j = 0

fishingPoints = 0

sum = 0

while j < numberOfCasts:

dieNum = randint(1 , 6)

if dieNum ==1:

fishingPoints = 2

elif dieNum == 2:

fishingPoints = 4

elif dieNum == 3:

fishingPoints = 6

elif dieNum == 4:

fishingPoints = 8

elif dieNum == 5:

fishingPoints = 10

elif dieNum ==6:

fishingPoints = 12

sum += fishingPoints

j++

if sum > 30:

print ("Great catch")

elif sum > 10 and sum <= 30:

print("Good catch")

else:

print ("Bad day")


Related Questions

Please Fix This For Me


print ("Please enter a number between 1 and 100")
n = input

if = n < 1 and n > 100:

if = (n // 2 == 0):
print (n, "is even")

if = (n // 3 == 0):
print (n, "is odd")

else:
print("You have not entered a number between 1 and 100.")

Answers

Answer:

The correction is as follows:

n = int(input("Please [tex]enter\ a[/tex] [tex]number\ between\ 1[/tex] and 100: "))

if n < 1 or n > 100:

   print("You [tex]have\ not[/tex] entered a [tex]number\ between\ 1[/tex] and 100.")

elif n % 2 == 0:

   print (n, "is even")

else:

   print (n, "is odd")

Explanation:

See attachment for explanation

Consider the following method:
public static String joinTogether(int num, String[] arr)
{
String result = "";
for (String x : arr)
{
result = result + x.substring(0, num);
}
return result;
}

The following code appears in another method in the same class:
String[] words = {"dragon", "chicken", "gorilla"};
int number = 4;
System.out.println(joinTogether(number, words));

What is printed when the code above is executed?
a. dragonchickengorilla
b. drachigor
c. dragchicgori
d. dragochickgoril
e. There is an error in the program, it does not run

Answers

Answer: b.

Explanation:

True or false you cannot get a computer virus is you instal antivirus

Answers

Answer: F

Explanation: There are many ways hackers can get into your computer, and many ways can bypass an antivirus so it is False

This is true because if you instal antivirus is no way the computer get virus then

How SPARQL 1.1 has advantage over SPARQL 1.0??​

Answers

SPARQL 1.0 became an official W3C Recommendation on 15 January 2008. On 26 March 2013, the SPARQL Working Group has produced a new W3C Recommendation SPARQL 1.1 that introduces more features to 2008 version. SPARQL is emerging as the de facto RDF query language. Prior to SPARQL, there were some other popular RDF query languages, such as RQL, SeRQL, TRIPLE, RDQL, and so on. The comprehensive...
Other Questions
How were the Nambicuara peoples similar to and different from the other main indigenous peoples of early Brazil? Explain some questions you might have about becoming a part of the MUN after reading the text. Which expression is equivalent to sqrt 36/25 OMG PLS HELP!!!!!!!!!!!!!! A rectangular prism has a height of 20 cm, length of 7 cm and width of 5 cm. Use the volume formula to find the volume of this prism. A. 140 cm3 B. 500 cm3 C. 700 cm3 D. 900 cm3 Which sentence best states the main idea of the first paragraph?O A.Parkour is a reinvention of the classic form of extreme sports.OB.Parkour does not have much in common with extreme sports.OC.Parkour is only dangerous when traceurs are not careful.ODParkour does not have many practitioners around the world. Wind power is an indirect form of what type of power? In what nation, which is considered the world's largest democracy, are coronaviruscases and new restrictions on the rise? Determine the equation of a circle with center at (8, 10) and radius is 6 How many grams is 2.40 x 1023 molecules of N,O,? (5 pts)PLS HELP ASAP Find the value of x and mHKL. A store is offering a discount of 15% on fishing rods what is the amount a customer will pay for a rod regularly priced at $25.00 What scientifically goes on with a plasma ball? The distance between Daytona Beach and Tallahassee is about 143,000 m. How many kilometers is this? friends help me outstate true or false0 is the multiplicative inverse of 0? Describe Truman's response on German's heavy reparations which was agreed at Yalta conference. What is a disadvantage to Florida's python hunt? How many miles are in 506,880 inches? What is the value, in degrees, of x? PLEASE HELP!!!!!!!!!!!!! 50 POINTS!!!!!!Here are four expressions that have the value -12:-14+(-14)121-214-12Write five expressions: a sum, a difference, a product, a quotient, and one that involves at least two operations that have the value -34. How can I express the composition of a solution?