#include <stdio.h>

void main(void)
{


 int principal; //원금
 double money; //최종금
 double rate;
 int year; //연도


 printf("Input principal and interest rate: ");
 scanf_s("%d %lf", &principal, &rate);


 year = 7200 / rate; //rule of 72로 복리계산
 printf("The total balance will exceed 2000 after %d years.\n", year);
 
}



원금 1000, 이율 0.02 입력하면 값이 36만년으로 나오네요 ㅠㅠ