For this PYTHON lab, we will use functions and imported functions to write a calculation program to do the following:


o Write a program that do the following unit conversion based on user menu selection: (use while

loop until the user enter ‘99’ selection to Quit)

1. Calculate Interest Rate

2. Calculate Mortgage

99 Quit


If user choice selection 1, then calculate interest rate. Modify your interest rate lab program

to be a function. Save this program to simple_interest.py filename in the current lab folder.

Use import to include the function in your main program.

o If user choice selection 2, then calculate mortgage. For this, you need to write a python

program function that will calculate mortgage payment. Save the program to mortgage.py

filename. You can modify the interest program with the following formulate:

1. How to calculate mortgage payment: (You MUST use the following test cases)

 Assume loanAmount = $100,000

 Assume interestRate = 3.25%

 Assume loanTerm = 15 years

 Then formula for mortgage calculation is:

monthlyRate = (interestRate / 100) / 12

numPayments = loanTerm * 12

monthlyPayment = loanAmount * monthlyRate \

* pow((1 + monthlyRate), numPayments) \

/ (pow((1 + monthlyRate),numPayments) - 1)

totalPayment = monthlyPayment * (loanTerm * 12)

interestPaid = totalPayment - loanAmount


 monthlyPayment would be: $702.67

 totalPayment would be: $126,480.38

 interestPaid would be: $26,480.38

PLEASE ANSWER WILL DO ANYTHING WILL MARK BRAINLIEST

Answers

Answer 1

Using the computational language in python it is possible to write a code that does the following unit conversion based on user menu selection:

Writing code in python:

def simple_interest(principal,rate,times,year):

       return principal + principal*(rate/times)*(times*year)/100.0

import simple_interest as si

from datetime import datetime

print("CNET-142: Ron Sha, Lab Menu Function\n",datetime.now())

def simpleInterest():

   print("\nCalulating Simple Interest")

   while True:

       principal = float(input("Enter the starting pricipal, <= 0 to quit: "))

       if principal > 0:

           rate = float(input("Enter the annual interest rate: "))

           times = float(input("How many times per year is the interest compounded? "))

           year = float(input("For how many years will the account earn interest? "))

           totalamount = si.simple_interest(principal, rate, times, year)

           print("At the end of ",year," years you will have $ ",totalamount," with interest earned $ ",totalamount-principal)

       else:

           print("Exiting Simple Interest program...")

           break

def mortagePayment():

   while True:

       loanAmount = float(input("Enter the loan amount, 0 to quit: "))

       if loanAmount>0:

           interestRate = float(input("Enter the loan interest rate: "))

           loanTerm = float(input("Enter the loan term (number of years): "))

           monthlyRate = (interestRate/100)/12

           numPayments = loanTerm*12

           monthlyPayment = round(loanAmount * (monthlyRate*pow((1+monthlyRate), numPayments))/ (pow((1+monthlyRate), numPayments)-1),2)

           totalPayment = round(monthlyPayment*(loanTerm*12),2)

           interestPaid = round(totalPayment - loanAmount,2)

           print("For the loan Amount of $",loanAmount," for ",loanTerm," years with interest rate of ",interestRate," %")

           print("The monthly payment is $",monthlyPayment)

           print("Total amount paid for this loan is $",totalPayment)

           print("Total interest paid for this loan is $",interestPaid)

       else:

           break  

def menuChoice():

   menuchoice = int(input("Select one of the command number above: "))

   if menuchoice == 1:

       simpleInterest()

       return

   elif menuchoice == 2:

       mortagePayment()

       return

   elif menuchoice == 99:

       print("Have a nice day...")

       global flag

       flag = 0

       return

   else:

       print("Error: command not recognised")

       menuChoice()

flag = 1

while flag == 1:

   print("\n------------------------------------------------------")

   print("1\tCalculate Simple Interest\n2\tCalculate Mortage Payment\n99\tQuit the Program")

   print("------------------------------------------------------\n")

   menuChoice()

See more about python at brainly.com/question/18502436

#SPJ1

For This PYTHON Lab, We Will Use Functions And Imported Functions To Write A Calculation Program To Do

Related Questions

_____ is not considered a challenge when designing applications for multicore systems. A) Deciding which activities can be run in parallel B) Ensuring there is a sufficient number of cores C) Determining if data can be separated so that it is accessed on separate cores D) Identifying data dependencies between tasks.

Answers

Answer:

B) Ensuring there is a sufficient number of cores.

A for construct is a loop construct that processes a specified list of objects. As a result, it is executed as long as there are remaining objects to process. True or false?

Answers

The for loop will always execute as long as there are remaining objects to process. It's a true statement.

What is a for loop?

A for loop is used to do something repeatedly.

The for loop iterate over an items.

In a simpler term, the for loop is used to repeat a section of code known number of times.

Therefore,  a for construct is a loop construct that processes a specified list of objects.

As a result, it is executed as long as there are remaining objects to process is a true statement.

learn more on for loop here: https://brainly.com/question/2374898

#SPJ2

the first daemon loaded on a linux system is _____.

Answers

On a Linux system, the first daemon that is loaded is known as init.

What is a daemon?

A daemon can be defined as a program that is designed and developed to run continuously and it's created to handle periodic service requests that are expected to be received on a computer system such as a Linux system.

On a Linux system, init simply refers to the first daemon that is loaded and it runs continuously.

Read more on Linux here: https://brainly.com/question/25480553

#SPJ12

What does a terminal access controller access control system plus (tacacs ) keep track of? check all that apply

Answers

The thing that the terminal access controller access control system plus keep track of is the log admin access to each device and the changes that are made.

Why is the control system important?

The control system is important as it's an authentication protocol used for remote communication.

Here, the terminal access controller access control system plus keep track of the log admin access to each device and the changes that are made.

Learn more about control system on:

brainly.com/question/25930304

#SPJ12

Which device limits traffic between server 1 and server 2 devnet

Answers

The device that limits traffic between server 1 and server 2 is known as a router.

What is a router?

It should be noted that a router is the device that connects two or more packet switched networks.

In this case, the device that limits traffic between server 1 and server 2 is known as a router. It manages traffic between the networks.

Learn more about router on:

brainly.com/question/24813743

#SPJ12

Hi Lesiana, After your presentation last week, the manager thinks an in-house solution is the way to go. Although our programmers have much experience with system integration and development, they have little experience with user design. You'll have to lay out all the pages of the system. For now, just create a hierarchical drawing of all the pages needed for this system. Think of the menu on the top of the screen and what you'd click on to move to the next screen.
Once you finish the hierarchy, I'll need you to draw out examples of a few of the screens. For example, show a screen with a menu, another which requests user input, one that has methods to contact us, and the last one as an informational page. The menu screen can be an opening page or even a page to decide on types of reports to run. The user input page can be one for any of the users, such as the appointment setters or technicians. Make sure that you outline all of the required validation rules for this input page. The informational page can either be a static page or results from a search. Make sure that you include navigation buttons on each of these example pages.

Answers

The Hierarchical drawing of the In- House solutions includes Four categories such as product, service, training, support and about.

What is Hierarchical drawing?

Hierarchical drawing is also known as Layered Graph Drawing which includes the drawing in the vertices and are made on the Horizontal rows and layers.

The complete solution is attached below.

The In-House solutions' hierarchical diagram covers four categories, including product, service, training, support, and about.

Learn more about Hierarchical drawing here:

https://brainly.com/question/26031625

#SPJ1

 

What tool can you use to identify a secure location.

Answers

The tools used to identify secure location are Sucuri SiteCheck, Mozilla Observatory, Detectify, SSLTrust and WPScan.

What is website security check tools?

The Website Security Check tool is used to scan and check safety of the websites and to look after the websites related problems faced by the users.

It also helps the users in whether the website is safe to visit or not and to share the information with.  

Sucuri SiteCheck, Mozilla Observatory, Detectify, SSLTrust, and WPScan are some of the tools used to determine secure locations.

Learn more about  website security here:

https://brainly.com/question/12588992

#SPJ1

A ________ implementation involves considerable modifications to the erp software

Answers

A chocolate implementation involves a good modifications to the ERP software.

What is chocolate implementation?

In the chocolate implementation, the is good system enhancement and it is known too be a  type of implementation that is said to be positive for the users as the package is often customized based on user needs.

Therefore, A chocolate implementation involves a good modifications to the ERP software.

Learn more about chocolate implementation from

https://brainly.com/question/23776149

#SPJ12

What does the subnet mask 255. 255. 255. 0 tell a router?

Answers

The subnet mask 255. 255. 255. 0 tell a router the part of an IP address that has or that is the subnet ID and the part that is host ID.

What does subnet mask tell a router?

The aim of the part of the mask that reads 255 is one that  tell a router the part of an IP address that is said to  be the subnet ID.

Note that A subnet mask helps to know which aspect of the IP address are known as the network and host identifiers.

Therefore, The subnet mask 255. 255. 255. 0 tell a router the part of an IP address that has or that is the subnet ID and the part that is host ID.

Learn more about subnet mask from

https://brainly.com/question/12858865

#SPJ12

why open source software is very important for the country like Nepal​

Answers

Collaboration promotes innovation through open source licensing. Many of the modern technology we take for granted would not exist today without it or would be hidden behind the restrictions of the patent system. Technology has advanced so quickly over the last few decades because of the open source movement.

Which arcade game, released in 1972, is considered to be the first to be commercially successful?.

Answers

Answer:

Pong

Explanation:

Pong

When designing a query in power bi desktop, what is the best datatype to use for column containing currency values?

Answers

In designing a query in power bi desktop, the best datatype to use for column containing currency values is fixed Decimal Number data type.

What is Fixed Decimal Number data type?

Fixed Decimal Number data type is said to be a kind of currency data type where the given location is said to be fixed for giving the decimal.

Note that in the above case, In designing a query in power bi desktop, the best datatype to use for column containing currency values is fixed Decimal Number data type.

Learn more about datatype from

https://brainly.com/question/179886

#SPJ12

What is open source software​

Answers

Answer:

Open Source Software

Explanation:

Open-source software is computer software that is released under a license in which the copyright holder grants users the rights to use, study, change, and distribute the software and its source code to anyone and for any purpose. Open-source software may be developed in a collaborative public manner.

Answer:

open so software is an computer software that is reliance in which copyright holding reference uses the rights use study change and disturb this software and it so scold to anyone for any propose also open source software maybe diplobed in collaborative public manner

Explanation:

helpful

2. Which domain represents the greatest risk and uncertainty to an organization?

Answers

Answer:

The User Domain

Explanation:

Since human behavior is unpredictable and impacted by forces outside of policy's control, the User Domain carries the most risk and uncertainty. The User Domain is a significant vulnerability in the IT architecture. Any end-user who accesses information at the organization falls within this domain. Employees who neglect to secure their laptops before leaving their offices, for example, or employees who leave critical corporate information on their desks. Such risks have the ability to ruin a company by falling for a social engineering technique can result in the introduction of viruses into the business network. It could result in the encryption of important files required for day-to-day processes. The only option in the lack of comprehensive backups of these documents would be to pay the blackmail. If the hackers unencrypt the data as they promise after the ransom is paid, this might result in days of lost work.

The domain that represents the greatest risk and uncertainty to an organization is known as the user domain.

What is a user domain?

It should be noted that a user domain simply means a vital vulnerability in the IT architecture.

Here, the domain that represents the greatest risk and uncertainty to an organization is known as the use domain.

Here, the username as password are stored on a domain controller.

Learn more about domain on:

brainly.com/question/26098895

#SPJ12

The time component of the FITT-VP principle for overload in a muscular strength program is Multiple Choice the same as that for a cardiorespiratory fitness program. based on the number of training days per week. based on the amount of weight lifted. based on the number of sets and repetitions of specific exercises.

Answers

The time component of the FITT-VP principle for overload in a muscular strength program is D. based on the number of sets and repetitions of specific exercises.

What is a strength program?

It should be noted that a strength program is a form of exercise that's done to increase one's strength.

In this case, the time component of the FITT-VP principle for overload in a muscular strength program is based on the number of sets and repetitions of specific exercises.

Learn more about strength program on:

brainly.com/question/1962479

#SPJ12

what statement can you use to divide a script into multiple batches?

Answers

The GO statement can be used to divide a script into multiple batches

How to determine the statement?

To divide a script, we make use of the GO statement or the GO command.

The GO statement has no syntax because it is not a keyword in SQL.

However, it is used by the SQL to create a group or batch of instructions that would be sent into the server

Read more about SQL at:

https://brainly.com/question/25694408

#SPJ11

what are the tags in html. Write its syntax.

Answers

Answer:

HTML is using tags for its syntax. A tag is composed with special characters: <, > and /. They are interpreted by softwares to compose an HTML element.

Explanation:

There are generally two types of tag they are;

1. empty tahg

2. container tag

Alex wrote a science fiction story about half-living, half-robot creatures in
another galaxy. He wanted to copyright the creature idea for later sequels but
was denied. What element was missing?
O A. Creativity
OB. Fixed form
O C. Interest
OD. Originality

Answers

Answer:

im not sure about this one but im pretty sure its d since this is not a original idea at all their are like tons of cyborn alien thing on their and this would not be original

Hope This Helps!!!

What is the best description of an unbound control?

it is connected to a table
it is linked to an external file
it is unlimited in character length
it is unlinked to a firm’s underlying data

Answers

It is unlinked to a firms underlying data

Which 3 file formats can be used for importing lists directly into quickbooks online?.

Answers

Answer:

Explanation:

QBO

IIF

QBJ

The name of 3 file formats that can be used for importing lists directly into QuickBooks online are,

1. Excel (XLS, XLSX)

2. CSV (Comma-Separated Values)

3. IIF (Intuit Interchange Format)

Given that,

To find names of 3 file formats that can be used for importing lists directly into QuickBooks online.

Now, Here are three commonly used file formats:

1. Excel: QuickBooks Online allows you to import lists such as customers, vendors, and products using Excel spreadsheets.

2. CSV (Comma-Separated Values): CSV files are widely used for data import/export. QuickBooks Online supports importing lists in CSV format.

3. IIF (Intuit Interchange Format): While not as commonly used as Excel or CSV, QuickBooks Online also supports importing lists using the IIF file format.

IIF files are specific to QuickBooks and provide a way to import various types of data, including lists.

To learn more about QuickBooks visit:

https://brainly.com/question/24441347

#SPJ4

The sorted values array contains the sixteen integers 1, 2, 3, 13, 13, 20, 24, 25, 30, 32, 40, 45, 50, 52, 57, 60. How many recursive calls are made by our binarySearch method given an initial invocation of binarySearch(45, 0, 15)

Answers

The number of recursive calls that have to be done using the binary search is 4.

How to do the recursive calls

binarySearch = (45, 0, 15)

start + end / 2 = value

mid = 0 + 15/2 = 7.5

The 7th element = 30

30 is less than 45

8 + 15/3

= 23/2 = 11.5

The 12th element = 52

52 is greater than 45

8 + 11/2

= 19/2 = 9.5

The value of 9 = 40 and 40 is less than 45

10+ 11/2 = 10.5

The tenth value is 45 hence the iteration to be done is 4.

Read more on binary here:

https://brainly.com/question/21475482

#SPJ1

A government authority or license excluding others from making, using, or
selling an invention without the creator's permission is called a
O A. patent
OB. Copyright
O c. trademark
OD. trade secret

Answers

Answer:

A. Patent

Explanation:

the internet is controlled by ______

Answers

In the case above, No one control the Internet.

What is the internet control about?

Note that no one and everyone has no control over the use of the Internet as it is said to be a network of networks.

Note that there are separate networks that is said to belongs to different firms and organizations as they have their own laws and regulations.

Therefore, In the case above, No one control the Internet.

Learn more about Internet from

https://brainly.com/question/2780939

#SPJ11

A common business practice is to include a worksheet named Documentation that contains a description of the workbook, the name of the person who prepared the workbook, and the date it was created. _________________________

Answers

A common business practice is to include a worksheet named Documentation that contains a description of the workbook, the name of the person who prepared the workbook, and the date it was created: True.

What is a worksheet?

A worksheet is also known as a spreadsheet and it can be defined as a type of document which comprises cells that are arranged in a tabulated format (rows and columns).

In Computer technology, some of the common business practice include the following:

Creating a worksheet named Documentation with a description of the workbook.The name of the person who prepared the workbook.The date it was created.

Read more on worksheet here: https://brainly.com/question/4965119

#SPJ1

As part of their extensive kitchen remodel, the Lees told their electrical contractors that they would need plenty of outlets for their many appliances. The contractors
knew that they would need to install small-appliance branch circuits using what kind of wire and circuit breaker?

Answers

The kind of wire and circuit breaker are:  grounding wire such as fairly large bare copper wire.

What is the best wire for the above?

A 20A, 120V small-appliance branch circuit is known to be  used in the case above.

Note that Electric range circuits needs about 50-amp, 240-volt made for circuit that is said to supplies the power to the range or oven via  a 6-3 electrical wire.

Learn more about circuit breaker from

https://brainly.com/question/8976395

#SPJ1

Human centered technology often recommends
to computer designers and manufacturers, telling them how to make systems and the devices that support them more user-friendly.

Answers

Human centered technology often recommends  best practices to computer designers and manufacturers.

What is Human centered technology?

Human-Computer Interaction is known to be a kind of a study that is said to be based  a lot on the design of computer technology and its relationship between humans and computers.

Note that, Human centered technology often recommends  best practices to computer designers and manufacturers.

Learn more about technology from

https://brainly.com/question/12081854

#SPJ1

Answer:

best practice

Explanation:

write the definition of a method reverse, whose parameter is an array of ints. the method reverses the elements of the array. the method does not return a value.

Answers

The reverse() method reverses the order of the elements in an array.

What is a reverse method?

The reverse() method reverses the order of the elements in an array.

The reverse() method overwrites the original array.

What the reverse method does in array is to change the order of the items in array in a descending order.

For example

var fruits = ["Banana", "Orange", "Apple", "Mango"];

fruits.reverse();

The fruits.reverse(); will return [Mango, Apple, Orange, Banana}

Notice it has been reversed.

The code it written in Javascript.

learn more on reverse method here: brainly.com/question/14500181

#SPJ2

What are 2 ways to send a message to your client when signed in as an accountant user?.

Answers

Answer:

The use of Ask client and request are 2 ways to send a message to your client when signed in as an accountant user.

What might you expect to find out about people who are described as credit risks?

Answers

What might you expect to find out about people who are described as credit risks? They have a history of not making their payments on time. Which is a long-term consequence of making late payments on your bills? It will be harder to secure a new loan at a low rate.

Bios or uefi allow you to configure, enable, and disable the _____ that are bound to the motherboard

Answers

Answer:

devices

Explanation:

BIOS and UEFI are two computer firmware protocols that act as an interpreter between the operating system and the computer firmware. Both of these interfaces are used at computer launch to setup hardware components and launch the operating system stored on the hard drive.

BIOS or uefi allow you to configure, enable, and disable the devices that are bound to the motherboard.

What is BIOS in motherboard?

BIOS is known to be the (basic input/output system)  and it is a program of the computer's microprocessor that often helps to start the computer system after it is said to be powered on.

Note also that BIOS or uefi allow you to configure, enable, and disable the devices that are bound to the motherboard.

Learn more about BIOS from

https://brainly.com/question/13103092

#SPJ12

Other Questions
write the structure of root URGENT + 20 Points! The regression equation for water being poured into a large, cone-shaped cistern is In(volume) = -1.327 +2.993 In(Time). What is the predicted volume for a time of 12 seconds?- There is a line above "(volume)" 1.810 cm36.110 cm334.589 cm3450.485 cm3 the price of an mp3 player is increased by 8%to 52.92what was the original price? Researchers designing studies to be conducted in host countries outside the u. S. Should: PLEASE HELP ILL GIVE BRAINLIEST PLEASE PLEASE PLEEEEEEEAAAAASEWrite the recursive formula for the arithmetic sequence.A(n)=(-1)+(n-1)(-5) A snowboarder on a slope starts from rest and reaches a speed of 4.2 m/s after 7.3 s Select the correct answer.Consider function f.f(x) = 2xWhat is the value of ()(x)O A.8x4OB. 16x4OC. 4x44x2D. In my country, we make so much waste-we buy and throw away, buy and throw away, buy and throw away-and yet northern countries will not share with the needy. Even when we have more than enough, we are afraid to share, we are afraid to let go of some of our wealth.The Girl Who Silenced the World for Five Minutes,Severn Cullis-SuzukiBased on the passage, why are the people in Suzukis country wasteful?because they do not have enoughbecause they are afraid of people in the southern countriesbecause they share too much with othersbecause they are afraid to lose wealth What two houses of Congress were created by the Great Compromise? Symptoms of malaria appears when In a train timetable, in order to estimatearrival and departure time, read thetimes from Which word is the best antonym for invincible. a. often victoriousb. quickly forgottenc. easily defeatedd. not athletic Want to earn 20 points for correct answer CLICK ME A firm operating in a perfectly competitive market is a price taker because: If side b measures 53, what is the length of side c? Development refers to the pattern of continuity and change in human capabilities that occurs _____. A medical assistant is answering the clinic phone. Which of the following guidelines demonstrates professional telephone etiquette? 50 people were asked if they speak French or German or Spanish. Of these people, 31 speak French 2 speak French, German and Spanish 4 speak French and Spanish but not German 7 speak German and Spanish 8 do not speak any of the languages all 10 people who speak German speak at least one other language How many people only speak Spanish? Hassan put 437.2 grams of brown sugar into a canister. Then he carefully measured out 430.43 grams of it to use in a recipe for cookies. How much brown sugar is left in the canister? What error did Lucia make?