Skip to content

setup assignment and started creating variables - #1

Open
NotYourSyn wants to merge 8 commits into
masterfrom
Chris-Reisner
Open

setup assignment and started creating variables#1
NotYourSyn wants to merge 8 commits into
masterfrom
Chris-Reisner

Conversation

@NotYourSyn

Copy link
Copy Markdown
Owner

No description provided.

@NotYourSyn NotYourSyn self-assigned this Apr 28, 2020
@NotYourSyn
NotYourSyn requested a review from katfsw April 29, 2020 02:24
Comment thread index.js
*/

let principal = 200000;
let interestRate = 0.05;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looking good!

Comment thread index.js


let monthlyInterestRate = interestRate/12;
let periods = years*12;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome!

Comment thread index.js
When your math is correct, monthlyRate will equal 1073.64
*/

let numerator = principal*monthlyInterestRate*(Math.pow(1+monthlyInterestRate,periods));

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome!

Comment thread index.js
let numerator = principal*monthlyInterestRate*(Math.pow(1+monthlyInterestRate,periods));
let denominator = (Math.pow(1+monthlyInterestRate,periods)-1);
let monthlyRate = numerator/denominator;
console.log('Monthly Rate:'+ monthlyRate.toFixed(2));

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice job!

Comment thread index.js
}

mortgageCalculator();

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great work!

Comment thread index.js
let monthlyRate = numer/denom;
monthlyRate = monthlyRate.toFixed(2);
return `${monthlyRate}`;
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looking good!

Comment thread index.js
}


mortgageCalculator(200000,0.05,30,750);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome! this looks great!

Comment thread index.js
monthlyRate = monthlyRate.toFixed(2);

return `${monthlyRate}`;
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥🔥🔥

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome .. Thank You .. this was a fun one ... had me up late lol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants