db << 'insert into user (age,name,weight) values (20,'bob',83. Or even better write youre constants into the SQL. Changing the constant '20' to a variable should fix that. Write a program that asks for the principal, the interest rate, and the number of times the interest is compounded. Hm, looks like youre compiler will not pass a const reference from a constant (rvalue), he is expecting a variable (lvalue) instead. Principal is the balance in the savings account, Rate is the interest rate, and T is the number of times the interest is compounded during a year (T is 4 if the interest is compounded quarterly). Hope, I didn't mess up with the quality of your answer. Copy Code #include #include using namespace std Ĭout < < " The total amount is : " < < amount < < endl Īssuming there are no deposits other than the original investment, the balance in a savings account after one year may be calculated as Plus, I made the change as to what Carlo has said above and the program is also C++ so I changed the function call, resource links.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |