BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Shrutibhatnagar
Obsidian | Level 7

hello,

their are two programs 

1) 

data earnings;
amount=1000;
rate=0.0375;
do month =1 to 12;
ci=(amount+earned)*rate;
earned+ci;
output;
end;
run;

this calculates compound interest 

and second one :

2)

data earnings;
do year=1 to 20;
capital+2000;
do month =1 to 12;
interest=capital*(0.075/12);
capital+interest;
output;
end;end;
run;

which is also calculating the interest but i dont know what is happening in the second .why do they divide by 12 ? 

 

 

 

 

 

 

1 ACCEPTED SOLUTION
2 REPLIES 2
Shrutibhatnagar
Obsidian | Level 7

what is the purpose of calculating interest this way when . Is it practically used ?

 

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 1243 views
  • 1 like
  • 2 in conversation