Tuesday, August 8, 2023

PETROL BUNK PROGRAM CODING

 INPUT:

  #include<stdio.h>

int main()

{

printf("  PETROL BUNK\n");

int litre,price ;

int day;

printf("1.sunday");

printf("2.monday");

printf("3.tuesday");

printf("4.wednesday");

printf("5.thursday");

printf("6.friday");

printf("7.saturday");

printf("enter the day:\n");

scanf("%d",&day);

printf("amount of litre:\n");

scanf("%d",&litre);

switch(day){

    case 1:

   

    price=100;

    break;

    case 2:

    

    price=200;

    break;

    case 3:

   

    price=300;

    break;

    case 4:

    

    price=500;

    break;

    case 5:

   

    price=100;

    break;

    case 6:

    

    price=200;

    break;

    case 7:

    

    price=300;

    break;

    

}

 

    printf("price per litre:rupees %d\n",price);

    printf("total price:rupees %d\n",litre*price);

    return(0);

}





OUTPUT:

 



USD TO INR C++ PROGRAMMING

  NALLAMUTHU GOUNDER MAHALINGAM COLLEGE                                                 POLLACHI-642001                                     ...