1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Oliga [24]
3 years ago
13

Grade 10 python exercise

Computers and Technology
1 answer:
lbvjy [14]3 years ago
7 0

number = 547

nums = {1:"one", 2:"two",3:"three",4:"four",5:"five",6:"six",7:"seven",8:"eight",9:"nine"}

print("The last digit of",number,"is",nums[number%10])

I wrote my code in python 3.8. I hope this helps.

You might be interested in
What does ‘‘negotiation’’ mean when discussing network protocols? give an example?
rewona [7]
Some protocols have multiple algorithms to choose from for e.g., cryptographic purposes. During connection set up, client and server negotiate which one they'll use.

One example is the set up of a TLS connection. During the handshake, the client shares a list of its supported ciphers (the 'ciphersuites'). The server responds by indicating the best one that both sides support.

4 0
2 years ago
11 of the 25 people on the bus get off at the first stop. What percent best represents the portion of the bus that got off on th
miskamm [114]

Answer:

44%

Explanation: First, you have to divided 11 by 25. Which is 0.44. And then you multiply the quotient by 100 to get your percentage.

5 0
2 years ago
Denise is working as a market analyst in a publishing house. What is her career field?
e-lub [12.9K]
Cynthia career field would be a office job such as assisting a CEO or leader of a company.
8 0
3 years ago
Read 2 more answers
Write a function named dice_eval that accepts two parameters representing numeric dice values and returns a string describing th
Zigmanuir [339]

Following are the "dice_eval" method code into python language.

Program Explanation:

  • Defining a method "dice_eval" that takes two variables "d1,d2" in its parametes.
  • Inside the method, multiple conditional statements were used that adds the parameter values and calculates its value which can be defined as follows:
  • In the if block, it adds the parameters and uses or gate that check its value that is equal to 7 or 11. so, it will return a string message that is 'Winner!'.  
  • In the elif block, it adds the parameters and uses or gate that check its value that is equal to 2 or 3 or 12. so, it will return a string message that is ' C r aps ! '.
  • In the else block, it uses a return keyword that adds parameter value and prints a string value.
  • Outside the method "d1,d2" is declared that inputs the value from the user-end, and passes the value into the method, and prints its value.

Program:

def dice_eval(d1, d2):#defining a method dice_eval that takes two parameters

if (d1+d2)==7 or (d1+d2)==11:#defining if block that adds parameter value and use or operator to check its value

return 'Winner!'#return string value

elif (d1+d2)==2 or (d1+d2)==3 or (d1+d2)==12:#defining elif block that adds parameter value and use or operator to check its value

return 'C r aps!'#return string value

else:#defining else block

return 'Point is '+str(d1+d2)#return string value with adding parameter

d1=int(input())#defining d1 that input value

d2=int(input())#defining d2 that input value

print(dice_eval(d1,d2))#calling method and print its return value

Output:

Please find the attached file

Please find the complete code in the attached file.

Learn more:

brainly.com/question/15011927

4 0
2 years ago
A shop will give discount of 10% if the
wlad13 [49]

Answer:

10%÷100 it is correct answer

6 0
2 years ago
Other questions:
  • One of the biggest risks involved in using e-mail is
    14·2 answers
  • Load the solver add-in if it is not already loaded. click the budget worksheet and set the objective to calculate the highest ba
    15·1 answer
  • What would happen if you clicked on the Show Desktop icon on your computer screen? The system tray would appear. All open window
    9·2 answers
  • Using underlining and italics at the same time is which of these? A. allowed but might be overkill B. always a good idea C. not
    15·2 answers
  • Which of the following is the result of a query?
    9·1 answer
  • What type of attacks take advantage of vulnerabilities in poorly coded web application software to introduce malicious program c
    9·1 answer
  • Histogram 9AMAA 12/01/2021.
    9·1 answer
  • Which of the following is a message sent from one person to another using the Internet?
    13·2 answers
  • 4.(L.5.1.A) Select the sentence that includes an interjection,
    12·1 answer
  • Write a method that makes the input string of sentences ending with and
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!