Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Computer Science Practical Material

Download as pdf
Download as pdf
You are on page 1of 10
A. SMALL / MINOR PROGRAMS | : 4 B. Program to print all numbers between 1 to 100 is divisible by 5&3. Bolution Numbers are Divisible by 5 & 3 15 30 45 60 75 90 y 4 UNIMAX ADVANCED PROGRAM RECORD FILE. [B LONG / MAJOR PROGRAM | 4, Program to check whether roots of quadratic equation are real or imaginary Solution: as ? /PROGRAM TO CHECK WF EQUAL .REAL OR / /AMAGINARY #inelude #include void main() gx int a.b,c,d,r1,r2; elrser0); printf“Enter Value’ of Ay scanfi“%d%d 7a d=((b*b)-(4*a¥e) ifid>d Enter Value of A, B & C 252 Roots are Real and Unequal itive, negative or zero Solution:- Enter N Enter Elements : 1 5 0 9 0 Positive numbers are : 2 Negative numbers are : 1 Zero numbers are : 2 String is in Lower Case : computer 20. Program to Solutic — #include void fibtint); void main() ( int n; eirser(); printf“Enter number upto you Want to scantl“éd”,&n); fib(n); getch(); ! void fibjint m) i int a=0,b=1,c=1,5; printh%d %d “abi; while(ec=(m-2)) Program to swap a number using call by ition: PROGRAM TO SWAP TWO..NUMBERS USING GALL BY RE #include #include swap(int*, int*); void main() int m,n; clrser(); intfl“Enter Value of A :"); iscanfl“%d",&m) printf{“Enter Value of B :”): seanfl“ed” Sn swap(&m,&n); Eprintf“Value of A and B after Swapping %d %éd” m,n); getch() Output ynio.h Jude

You might also like