Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8652677
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T14:21:46+00:00 2026-06-12T14:21:46+00:00

I have a homework to do and i did it. I am 95 %

  • 0

I have a homework to do and i did it. I am 95 % sure its a corect code. I dont have a clue why but unfortunally i got Syntax error in one of the lines. Here is my code:

month = 1
totalPaid = 0
while month <= 12:
    print('Month: ' + str(month))
    print('Minimum monthly payment: ' + str(round(monthlyPaymentRate * balance), 2)
    balance = round((balance - (monthlyPaymentRate * balance)) * (1 + (annualInterestRate/12)),2)
    print('Remaining balance: ' + str(round(balance, 2)))
    month = month + 1
    totalPaid = totalPaid + round((monthlyPaymentRate * balance), 2)
print('Total paid: ' + str(totalPaid))
print('Remaining balance: ' + str(balance))

I got Syntax error on this line: balance = round((balance – (monthlyPaymentRate * balance)) * (1 + (annualInterestRate/12)),2). It is probably something very simple but i am novice in Python and cant understand what exactly is the problem, i know that Python is very sensative about spaces and indents and i was carefull about that. Any suggestions ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T14:21:47+00:00Added an answer on June 12, 2026 at 2:21 pm
    print('Minimum monthly payment: ' + str(round(monthlyPaymentRate * balance), 2)
    

    has three open parens, but two close parens.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have homework i cant figure out. I know c++ but i am not
I have this homework that I gotta finish, but then something about it is
I have a homework assignment, and i am finished other then one question (see
Yeah, I did my homework and I found the setFrame:frame display:YES animate:YES but I
I did my homework, and the code works and does what I want. The
I went through all the questions on SOF and did my homework but still
I have a homework that include a new operation (a [n] b), given: a
I have a homework in which i have 640x480 image and i want to
I have a homework problem here I've been working on; here is the description:
I have a homework task to prove whether or not a particular variation on

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.