PROBLEM SOLVING USING C LAB Programs -JNTUK(R20)
Excercise -1 |
---|
Write a C program to print a block F using hash (#), where the F has a height of six characters and width of five and four characters. /* Write a C program to print a block F using hash (#), where the F has a height of six characters and width of five and four characters. */ #include<stdio.h> int main( ) { printf("######\n"); printf("#\n"); printf("#\n"); printf("#####\n"); printf("#\n"); printf("#\n"); printf("#"); return 0; } Output: |
Write a C program to compute the perimeter and area of a rectangle with a height of 7 inches and width of 5 inches. /*Write a C program to compute the perimeter and area of a rectangle with a height of 7 inches and width of 5 inches. */ #include |
Write a C program to display multiple variables. /* Write a C program to display multiple variables. */ int main( ) { char c='V'; int i=678; float f=12.23; double d=12.123456789; printf("Character = %c\n",c); printf("Integer = %d\n",i); printf("Float = %f\n",f); printf("Double = %lf\n",d); return 0; } Output: Character = V Integer = 678 Float = 12.230000 Double = 12.123457 |
Excercise -2 |
Write a C program to calculate the distance between the two points. /* Write a C program to calculate the distance between the two points. */
Enter the coordinates of first point(x1,y1):3 7 Enter the coordinates of the second point(x2,y2):5 8 Distance = 2.236 |
Write a C program that accepts 4 integers p, q, r, s from the user where r and s are positive and p is even. If q is greater than r and s is greater than p and if the sum of r and s is greater than the sum of p and q print "Correct values", otherwise print "Wrong values". Complete Lab Manual Download Below |
Classic Titanium Shaving Razors with Classic Blades - TITNIA
ReplyDeleteClassic titanium flash mica Titanium Shaving Razors with Classic Blades - TITNIA. titanium nitride gun coating One of the most reliable revlon hair dryer brush titanium of quality products. titanium eyeglass frames Includes one of the titanium coating most unique