Answer:
def main():
principal = float(input("Enter the amount of principal amount to be deposited: "))
rate = float(input("Enter annual interest rate paid by the account: "))
num = int(input("Enter the number of times per year that the interest is compunded: "))
years = float(input("Enter the number of years the account will be left to earn interest: "))
amount = principal*(1+(rate*.01)/num)**(num*years)
print("The amount of money will be in the account after ", years, "years:", round(amount,2))
main()
Explanation:
- Calculating the balance of the account after a specified number of years with the help of the formula:
- amount = principal*(1+(rate*.01)/num)**(num*years)
Answer:
Following is the definition of the required function:
def powerTo( double first, int second);
if second > 0;
double result = pow(first,second);
return result;
else
return 0;
Explanation:
The explanation for above code is as follows:
- A function named powerTo is defined, having two arguments with data type double and integer respectively.
- A if condition is applied that checks the second parameter.
- If the the condition: second > 0 gets true, a value is returned which is equal to first parameter raised to the second.
- If the condition is if bracket gets false, 0 is returned as a result.
i hope it will help you!
Answer:
Both TIFF and BMP are bitmap files, but TIFF files contain tags with additional information, like color space, resolution and print size, and can have 16-bit/channel depth (BMP's are limited to 8 bit). Taking a step back, there's no significant problem with first-generation JPEG files which use moderate compression.
Explanation:
It says you’ve only answered 11, but yeah it you’re account CAN be hacked
The answer is option C: Use ground-fault circuit interrupters, and inspect extensions cords and portable tools.
Inspecting the extension cords needs to be done constantly, or there can be abrasions or cuts that won't be noticed. Option B remains one of the most important ways to be safe around electricity. Always wear non-conductive safety equipment, such as safety goggles or rubber gloves. You should also avoid touching exposed metal. Option C indicates one of the two ways that do not help you stay safe around electricity. A ground fault interrupter only works if there is a short circuit or a huge amount of energy going through that point and thus, will not effectively protect you from possible incidents with electricity.