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
xxMikexx [17]
4 years ago
12

Create class SavingsAccount. Use a static variable annualInterestRate to store the annual interest rate for all account holders.

Each object of the class contains a private instance variable savingsBalance indicating the amount the saver currently has on deposit. Provide method calculateMonthlyInterest to calculate the monthly interest by multiplying the savingsBalance by annualInterestRate divided by 12- this interest should be added to savingsBalance. Provide a static method setInterestRate that sets t
Computers and Technology
1 answer:
emmasim [6.3K]4 years ago
8 0

Answer:

Class SavingsAccount( ):

annual_interest_rate

def.__init__(self, savings_balance):

self.savingsBalance = savings_balance

def calculatMonthlyInterest( ):

self.savingsBalance += (self.savingsBalance * annual_interest_rate) /12

return self.savingsBalance

def setInterestRate_(self, value):

self.annual_interest_rate = value

Explanation:

The python class above is used to create a savings account data for a customer, with methods to change the static interest rate and to calculate the monthly interest rate.

You might be interested in
Cell references in a formula are called _____.<br> a. assumptionsc. numbersb. valuesd. content
Airida [17]
It would bbe d because content is what is in something
7 0
4 years ago
Which of the following statements is TRUE? A. A name error occurs if the variable is referenced before it is declared. B. A name
lisov135 [29]

Answer:

A is the correct answer.

8 0
2 years ago
Suppose Alice, Bob, and Carol want to use secret key technology to authenticate each other. If they all used the same secret key
HACTEHA [7]

Answer:

No. This is not more secure.

Explanation:

this is not more secure than having all of Carol, bob and Alice having the same key.

alice would be able to know Carol's key for her to be able to verify the answer Carol gave to a challenge by her. she would also have to know bob's key to do the same.

any of these 3 would have to know someone else's secret key to verify answers to any challenge.

the challenge is to know the secret keys if the other two and if done, decryption can easily be done and they can impersonate.

8 0
3 years ago
Use the variables k, d, and s so that they can read three different values from standard input--an integer, a double, and a stri
Nat2105 [25]

Answer:

The c++ program to implement the given scenario is shown below.

#include <iostream>

using namespace std;

int main() {

   // variables declared as mentioned

   int k;

   double d;

   string s;

   cout << " Enter an integer value, a double value, a string value in the mentioned order " << endl;

   cin >> k >> d >> s;

   // variables printed in reverse order

   cout << " Reverse order " << endl;

   cout << s << " " << d << " " << k << endl;

   // variables printed in original order

   cout << " Original order " << endl;

   cout << k << " " << d << " " << s << endl;

   return 0;

}

OUTPUT

Enter an integer value, a double value, a string value in the mentioned order  

12 45.67 brainly

Reverse order  

brainly 45.67 12

Original order  

12 45.67 brainly

Explanation:

1. All the variables are declared as mentioned in the question.

int k;

   double d;

   string s;

2. The user is prompted to enter values for integer, double and string variables respectively. The input is accepted in the order mentioned above.

cin >> k >> d >> s;

3. The input is accepted in a single line since this is mentioned in the scenario that variables should be printed in the order in which they are read.

4. These variables are displayed to the standard output in reverse order – string, double, integer. The variables are displayed with exactly one space in between them.

cout << s << " " << d << " " << k << endl;

5. Then, variables are displayed in the original order – integer, double, string. The variables are displayed with exactly one space in between them.

cout << k << " " << d << " " << s << endl;

7 0
3 years ago
Explain what mistake Miranda made in the following scenario. Situation: Miranda suspects that there may be a problem with the ha
Dennis_Churaev [7]

Answer: Answer below.

Explanation:

I'm not fully sure myself, so don't agree with me fully.

I believe what she may have done wrong is tell the technician about a "program." A program doesn't have to do anything with physical hardware.

5 0
3 years ago
Read 2 more answers
Other questions:
  • What does this say:<br> √ans
    6·2 answers
  • In this exercise, use the following variables : i,lo, hi, and result. Assume that lo and hi each are associated with an int and
    9·1 answer
  • COMPUTER ORGANIZATION &amp; ARCHITECTURE I question 3<br> need correct the answers to all
    12·1 answer
  • There was a thunderstorm in your area and the power is out. The traffic lights are not functioning. Explain what you should do w
    8·2 answers
  • Write the definition of a function named printstarbucks that receives a non-negative integer n and prints a line consisting of n
    6·1 answer
  • Using C++
    15·1 answer
  • Supports traditional transactional processing for day-to-day front-office operations or systems that deal directly with the cust
    11·1 answer
  • BRAINLIEST!!! 20 PNTS!!!! HELPP!!!
    12·1 answer
  • HELP FAST
    14·1 answer
  • What is the best example of personally identifiable information.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!