multi functional math calculator in c : i need write code to create a simple calculator using c language.
i need to put some basic function in here.

#include<stdio.h>

void main ()

{

int a,b,sum;

printf("");

scanf("%d",&a);

printf("");

scanf("%d",&b);


 

printf("enter 1 to add,2 to sub,3 to divi,4 to mul");

 scanf("%d",&sum);


int add = a+b, sub =a-b,divi=a/b,mul=a*b;

   

if(sum==1)
 printf("add of two  values= %d",add);
    
if(sum==2)
 printf("sub of two values=%d",sub);
    
if(sum==3)
 printf("divi of two values=%d",divi);
    
if(sum==4)
 printf("mul of two values=%d",mul);
 

}

this code terminate when input two integers and give the oprtion.i need write the code to terminate the code when i give "="

