WAP to calculate the perimeter of rectangle

//WAP to calculate the perimeter of rectangle//


#include<stdio.h>
#include<conio.h>
void main()
  float l, b, peri;
  printf("Enter the length of rectangle\n");
  scanf("%f", &l);
  printf("Enter the breadth of rectangle\n");
  scanf("%f", &b);
    peri=2*(l+b);
  printf("Perimeter of rectangle is:-  %f", peri);
  getch();
}


  •   The Input and Output of this program are shown in the pictures below:-                                                                                                                                                                                                                                                           INPUT                                                                                                                                                                         
                              
                                                  

                                                                             OUTPUT                                                                                                                                                                                                                                                                                                                                                                
  
             

Comments