在C语言中设置指数增长函数X = a(1 + b)^ t

我正在编写一个程序,使用指数增长函数(X = a(1 + b)^ t)来跟踪一周内制作的矩形的数量。一个人每天可以制作60个矩形。

我在开始解决该问题时遇到了困难,请提供一些指导。

我当时在考虑使用math.h和pow,就像这样(这段代码未编译)


#include <math.h>
#include <stdio.h>
#include <stdlib.h>


int main() {

    int initial_POPULATION;
    int time_INTERVAL; 
    double growth_RATE;

    printf("How many people are making rectangles at the 
    biginning of the week?\n");
    scanf("%d", &initial_POPULATION);

    printf("How many people are making rectangles each day? 
    \n");
    scanf("%1f", &growth_RATE);

    //Exponential growth function X = a(1+b)^t
    printf("%d rectangles will be made this week!\n",
        initial_POPULATION(pow(1+growth_RATE),time_INTERVAL));

    return 0;

}