#include<stdio.h>
#include<conio.h>
struct speed;
{
int rate;
float weight;
float distance;
};
void main()
{
struct speed sp;
printf("\n enter distance");
scanf("%f",&sp.distance);
printf("\n enter weight");
scanf("%f",&sp.weight);
if(sp.distance <=40 && sp.weight<=100)
{
printf("\n you have charged 20 rupees");
}
elseif(sp.distance<=40 && sp.weight>=100 && sp.weight<=100)
{
printf("\n rate si 40 rupees");
}
elseif(sp.distance>=41 && sp.distance<=100 && sp.weight>=200 && sp.weight<500)
{
printf("\n rate is 70");
}
else
{
printf("\n rate is 100");
}
getch();
}