Category Archives: C Language

C Program To Calculate Circumference of Circle

Q: Write a C Program To Calculate Circumference of Circle. Input radius of the circle from the user at run time. Use the formula: circumference of circle = 2 * PI * radius The Logic Behind C Program to Find Circumference of Circle This is a simple C program using formula calculation technique. The basic… Read More: C Program To Calculate Circumference of Circle »

Loading

C Program to Search Multiple Records of Given Name in Binary File

Q: Write down a C Program to Search Multiple Records of Given Name in Binary File. As we have seen earlier a simple version of this program to search the first record with given name in a binary file. This program will show all such records having the given name of student in a binary… Read More: C Program to Search Multiple Records of Given Name in… »

Loading

C Program to Find Smallest Number in Array

Q: Write a C Program to Find Smallest Number in Array The Basic Logic of Smallest Number in Array Program First of all the user will input any 5 numbers in array. The program assumes that the first number is minimum number min = numArray[0]; This C program uses a for loop to get each… Read More: C Program to Find Smallest Number in Array »

Loading

C Program to Find Largest Number in Array

Q: Write a C Program to Find Largest Number in Array. The Basic Logic Behind Finding Maximum Number in Array First of all the user will input any 5 numbers in array. The program assumes that the first number is maximum number max = numArray[0]; This C program uses a for loop to get each… Read More: C Program to Find Largest Number in Array »

Loading

C Program to Check Positive Negative or Zero

Topic: C Program to Check Positive Negative Q: Write a C Program to use simple if statement to check positive negative or zero How to check for positive number A number is positive if it is greater than 0 (zero). Use simple if statement. if (number > 0) printf(“Number is positive”); What is the condition… Read More: C Program to Check Positive Negative or Zero »

Loading

C Program to Calculate Square Root of a Positive Number

Q: Write a C Program to Calculate Square Root of a Positive Number How To Calculate Square Root of a number in C Programming We use built-in function sqrt() to calculate square root of a number. Include Header File math.h for sqrt() function We must include math.h header file with the help of pre processor… Read More: C Program to Calculate Square Root of a Positive Number »

Loading

C Program to Search a Record by Name in Binary File

Q: C Program to Search a Record by Name in Binary File Input for C Program to Search Record by Name This C program will take the name of student to search in the binary file. How  To Search a Record By Name in File? This program will open the given file in read mode.… Read More: C Program to Search a Record by Name in Binary… »

Loading

C Program to Search a Record in Binary File C Programming

Q: Write a C program to Search a Record in Binary File in C Programming. What is the input of Record Search C Program? This C program will input a field to start a search with. For example, in a student binary file, we will input roll number of the student to start search in… Read More: C Program to Search a Record in Binary File C… »

Loading

C Program to Append / Add More Records in Binary File

To day we will learn to write a “C Program to Append / Add More Records in Binary File”. Let us study some important concepts related to appending a file in C Programming. What Do You Mean By Appending a File? By Appending a file we mean adding More records at the end of a… Read More: C Program to Append / Add More Records in Binary… »

Loading

C Program to Read Records From Binary File

C Program to Display Records From Binary File “Read Records From Binary File” in C Programming is the program we will write today. We have already written a C program to Write Records in a Binary File. We have learned some basic standard library function used in C File programming. fopen() to open a file.… Read More: C Program to Read Records From Binary File »

Loading