Posts

Chapter 1 Program 2

Image
Also visit our YouTube Channel Tech Eos     VISIT CHANNEL /*      2. Find the area and perimeter of square and rectangle. Input the side(s) through the keyboard.      */ #include<stdio.h> #include<conio.h> void main() { int a , area_of_square , perimeter_of_square ;   //FOR Square         // FOR Rectangle int length , width , area_of_rectangle , perimeter_of_rectangle;   clrscr(); printf("\nEnter value of a : "); scanf("%d" , &a); // area of square formula -->>   (a*a) area_of_square = (a*a); //perimeter of square formula -->> (4*a) perimeter_of_square = (4*a); printf("\n\nArea of Square    :  %d " , area_of_square ); printf("\nPerimeter of Square :  %d " ,                     ...

Chapter -1 Program -1

Image
Also visit our YouTube Channel Tech Eos    VISIT CHANNEL /* 1 . Find the Simple Interest. Inputs are principal amount,    period in year and rate of interest.    */ void main() { float principal_amount , rate_of_interest ; int peroid_in_year; float simple_interest ; clrscr(); printf("\nEnter principal amount : "); scanf("%f" , &principal_amount); printf("\nEnter rate of interest : "); scanf("%f" , &rate_of_interest); printf("\nEnter peroid of year   : "); scanf("%d" , &peroid_in_year); //    Simple Interest Fromula     (p*r*n)/100 simple_interest = ( principal_amount * rate_of_interest * peroid_in_year )/100; printf("\n\nSimple Interest is  %f " , simple_interest ); getch(); }