[1-1]

#include<stdio.h>

void main(void)

{

 int number, weight, total;

 

 number=3;

 weight=13.3;

 total=number*weight;

 printf("Total weight = %d\n",total);

}

 

[1-2]

#include<stdio.h>

void main(void)

{

 int number;

 float weight, total;

 

 number=3;

 weight=13.3;

 total=(float)number*weight;

 printf("Total weight = %f\n",total);

}

 

[1-3]

#include<stdio.h>

float total_weight(int,float);

 

void main(void)

{

 int number;

 float weight, total;

 

 number=3;

 weight=13.3;

 total=total_weight(number,weight);

 printf("Total weight = %f\n",total);

}

 

float total_weight(int n,float w)

{

 float t;

 

 t=(float)n*w;

 return(t);

}