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
Rom4ik [11]
2 years ago
6

Python exercise grade 10

Computers and Technology
1 answer:
guapka [62]2 years ago
7 0

earliest = ""

while True:

   month = int(input("Enter a date (month): "))

   day = int(input("Enter a date (date): "))

   year = int(input("Enter a date (year): "))

   if month == 0 and day == 0 and year == 0:

       break

   if month < 10:

       month = "0"+str(month)

   if day < 10:

       day = "0"+str(day)

   string_date = str(month)+"/"+str(day)+"/"+str(year)

   print(string_date)

   if earliest == "":

       earliest = string_date

   else:

       year,month,day=int(year),int(month),int(day)

       lst = list(map(int,earliest.split("/")))

       if year < lst[2]:

           earliest = string_date

       elif year == lst[2] and month < lst[0]:

           earliest = string_date

       elif year == lst[2] and lst[0] == month and day < lst[1]:

           earliest = string_date

print(earliest,"is the earliest date")

I wrote my code in python 3.8. Best of luck.

You might be interested in
Do AirPods Pro have a green flashing light when charging?
olasank [31]

Answer:

yes

Explanation:

3 0
3 years ago
Read 2 more answers
It was field day for the upper grades at Rock Creek School,
Mariulka [41]

Answer:

its c

Explanation:

8 0
3 years ago
Assume that the array arr has been defined and initialized with the values {4, 2, 5, 3, 1}. What are the values in the array arr
Murrr4er [49]

Answer:

arr = [4, 2, 5]

Explanation:

The while loop will remove the array elements from the back.

5 0
3 years ago
A manager would like information on the knowledge base searches conducted by customers and call center agents. Which two metrics
RideAnS [48]

Answer:

Option A and Option D are the correct options.

Explanation:

While any information is provided by the manager to its customers which is based on the knowledge of the search conducted.

So, the following knowledge is about the article of the lowest rating and about the search query that has no output.

  • Option B is not correct for the following scenario because the manager is informing about the searches conducted by customers, not for the data category.
  • Option C is not correct for the following scenario because the articles are not created by them.
3 0
3 years ago
5(x + 4) = 4(x -6) |<br><br><br>How to do this problem
vichka [17]
5 ( x + 4 ) = 4 ( x - 6)
5x + 20 = 4x - 24
5x -4x + 20= 4x - 4x - 24
1x + 20 = -24
1x + 20 - 20 = -24 - 20
1x = -44

check

5 (-44 + 4) = 4 ( -44 - 6)
5 (-40) = 4 (-50)
-200 = -200
3 0
3 years ago
Other questions:
  • Objective:This assignment is designed to give you experience with thinking about algorithm analysis and performanceevaluation.Pr
    11·1 answer
  • "The pkill command terminates _________."
    14·1 answer
  • which software is used to mimic intricate hand drawings into digital paintings? _____ is used to replicate hand drawings into di
    7·1 answer
  • The objective of ____ testing is to identify and eliminate execution errors that could cause a program to terminate abnormally,
    15·1 answer
  • ap csp The local, remote, and upstream _______ can each have multiple ___ _____. When a participant in a collaborative group on
    5·1 answer
  • Write a program to read a list of exam scores given as integer percentages in the range 0-100. Display the total number of grade
    10·1 answer
  • A computer operating system software manufacturer invests its profits in creating newer versions of its operating system softwar
    7·1 answer
  • A or an is a simple chip with two or more processor core
    5·1 answer
  • The foundation of secure communication on the internet replies on asymmetric encryption, with the use of Public and Private keys
    10·1 answer
  • Does digital media play a big role in your life?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!