#include<stdio.h>

int main()
    {
        float p,w,l,b,h,i,c,q,s,f,v,m;

        printf("Enter the value of point load, distributed load, length of span, breadth and height of beam=\n");
        scanf("%f%f%f%f%f",&p,&w,&l,&b,&h);

        c=h/2;
        i=(b*(h*h*h))/12;
        q=b*(h/2)*(h/4);
        v=p+(w*l);
        m=p*l+(w*l*l)/2;
        s=(v*q)/(i*b);
        f=(m*c)/i;

        printf("Shear=%.2f\nMoment=%.2f\nShearing Stress=%.2f\nFlexural Stress=%.2f",v,m,s,f);
        
        return 0;
    }
