Answer:
investmentAmount = float(input("enter the investment amount: "))
annualInterestRate = float(input("enter the Annual Interest Rate: "))
numYears = int(input("Enter NUmber of Years: "))
monthlyInterestRate = annualInterestRate/12
futureInvestmentValue = investmentAmount * (1 + monthlyInterestRate)*(numYears*12)
print("The Future Investment Value is: ")
print(futureInvestmentValue)
Explanation:
Using python programming language as required, we use the input function to prompt user for inputs for each of the variables.
There is a conversion from the variable annualInterestRate to monthlyInterestRate before the formula for the futureInvestmentValue is applied
Okay then that’s pretty cool
Answer:
Step Out
Explanation:
In the field of computer science, the control flow or the flow of control is defined as the order where the individual statements, or instructions of a program are
The Step Out control flow program runs to the and it resumes the at the statement that it follows.
Answer:
Class are the collection of variable and member function.
Class are the blueprint of an object.
Explanation:
Following are the points regarding class in c++
1.In C++ class is an user defined datatype..
2.Classes are the collection of variable and function in c++.
3.To access the property of class we can create object of that class
4.We can use following syntax to declared any class in c++
class classname
{
accessmodifier:
//statement and function
};
main()
{
classname objectname;
}
implementation of class in c++
#include<iostream>
class test // class declaration
{
public: // access modifier
void fun3() // Method definition
{
cout<<" hello :";
}
};
void main() // main function
{
test ob;// creating object
ob.fun3(); // calling function
}
In this program we declared a class "test " in class test. We giving public access modifier .The public access modifier define that variable and function are accessible outside the class and in main method we create the object ob which call the function fun3().
Output:hello :