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
Helga [31]
2 years ago
15

Your program is going to compare the distinct salaries of two individuals for the last 5 years. If the salary for the two indivi

dual for a particular year is exactly the same, you should print an error and make the user enter both the salaries again for that year. (The condition is that there salaries should not be the exact same).Your program should accept from the user the salaries for each individual one year at a time. When the user is finished entering the salaries, the program should print which individual made the highest total salary over the 5 year period. This is the individual whose salary is the highest.You have to use arrays and loops in this assignment.In the sample output examples, what the user entered is shownin italics.Welcome to the winning card program.
Enter the salary individual 1 got in year 1>10000
Enter the salary individual 2 got in year 1 >50000
Enter the salary individual 1 got in year 2 >30000
Enter the salary individual 2 got in year 2 >50000
Enter the salary individual 1 got in year 3>35000
Enter the salary individual 2 got in year 3 >105000
Enter the salary individual 1 got in year 4>85000
Enter the salary individual 2 got in year 4 >68000
Enter the salary individual 1 got in year 5>75000
Enter the salary individual 2 got in year 5 >100000
Individual 2 has the highest salary
Computers and Technology
1 answer:
kirza4 [7]2 years ago
4 0

In python:

i = 1

lst1 = ([])

lst2 = ([])

while i <= 5:

   person1 = int(input("Enter the salary individual 1 got in year {}".format(i)))

   person2 = int(input("Enter the salary individual 1 got in year {}".format(i)))

   lst1.append(person1)

   lst2.append(person2)

   i += 1

if sum(lst1) > sum(lst2):

   print("Individual 1 has the highest salary")

else:

   print("Individual 2 has the highest salary")

This works correctly if the two individuals do not end up with the same salary overall.

You might be interested in
Which of the following is a sigh that your computer may have been infected with malicious code
taurus [48]

Slow computer, blue screen, Programs opening and closing automatically, Lack of storage space, Suspicious modem and hard drive activity, Pop-ups, websites, toolbars and other unwanted programs, or spam.

4 0
3 years ago
How is it possible to find encyclopedias and reference texts on the internet
mariarad [96]

Answer:

just look up encyclopedias

Explanation:

3 1
3 years ago
Read 2 more answers
Assume that a signal is encoded using 12 bits. Assume that many of the encodings turn out to be either 000000000000, 00000000000
Mashcka [7]

Answer:

The following is the answer to this question:

Explanation:

In the binary digit

000000000000 is equal to 0 bit

000000000001 is equal to 1 bit

1 1 1 1 1 1 1 1 1 1 1 1 is equal to 10

Similarly,

000000000010=11

Thus,

00 \ 00 \ 01 \ 10\  010101010101 is equal to

000000000000, 000000000000, 000000000001 ,

000000000010,  1 1 1 1 1 1 1 1 1 1 1 1 , 000000000001 , 000000000001 , 000000000001 ,  

000000000001 , 000000000001 , 000000000001

8 0
3 years ago
Shania has started a new job as an app developer. Her first task was to make an old app designed for Android available on other
Fantom [35]

Answer:

B. Use cross-platform tools to write code that will translate the existing Android app code into different native formats.

Explanation:

Cross-platform application development tools are tools that can be used tool generate applications of different platforms, by just writing a single type of code. It has the ability to automatically create an application of a different platform from another.

A developer can develop an application like Android and convert it to IOS for Apple. Xamarin, Appcelerator coroner etc, are all examples of cross-platform tools.

8 0
3 years ago
You are running your warehouse using Autonomous Data Warehouse (ADW) service and you noticed that a newly configured batch job i
Phantasy [73]

Answer:

<u>C. The new batch job is connected to the LOW consumer group.</u>

Explanation:

<em>Remember</em>, one of the main characteristics of the LOW consumer group <u>database service</u> is that queries would run serially.

Since in this case, we are told that the newly configured batch job is always running in serial, it most likely would be because the new batch job is connected to the LOW consumer group; as queries are designed to always run serially.

6 0
3 years ago
Other questions:
  • All languages from the second generation on must be translated into machine language for the computer to be able process the inp
    8·1 answer
  • Which computer is the best for video cutting?
    11·2 answers
  • How many much memory is in one megabyte ?
    9·1 answer
  • Lisa managed incident response for a bank. The bank has a website that’s been attacked. The attacker utilized the login screen,
    9·1 answer
  • What is the best way of farming exotics in destiny?
    12·2 answers
  • What is problem scoping
    14·1 answer
  • Write a program that inputs numbers and keeps a running sum. When the sum is greater than 100, output the sum as well as the cou
    13·1 answer
  • Example of language processor software
    8·1 answer
  • Which wireless standard runs on both the 2.4 and 5 GHz frequencies?
    11·1 answer
  • Suppose a large group of people in a room were all born in the same year. Consider the following three algorithms, which are eac
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!