#include <stdio.h>

int main() {
    int n;
    float total=0;
    printf("combien de photocopies voulez-vous ?\n");
    scanf("%d\n",&n);
    if (n>10) {
        total+=1;
        if (n>30) {
            total+=1.8;
            total+=(n-30)*0.08;
        }
        else 
            total+=(n-10)*0.09;
    }
    else 
        total+=n*0.1;
    printf("La facture est de %f\n",total);
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: