C Program To Find The Roots Of Quadratic Equation

A quadratic equation has the form ax² + bx + c = 0, where a ≠ 0. Its roots are found with the quadratic formula: x = (−b ± √(b²−4ac)) / 2a. The value under the square root — b²−4ac — is called the discriminant (D) and determines what type of roots exist: Discriminant Roots …

Prime Number Program in C – Check if a Number is Prime

A prime number program in C checks whether a given integer is prime — divisible only by 1 and itself. Numbers like 2, 3, 5, 7, 11, and 13 are prime; 4, 6, 9, and 12 are not. This page covers two approaches: a basic trial division and an optimized version that skips even numbers, …

C Program to check whether a given 5 digit number is palindrome or not

C program to check whether a given 5 digit number is palindrome or not. Palindromic number is a number that remains same, when it is reversed or can be read in the same way in either direction.Example:12321, 23132… Read more about C Programming Language . Read more Similar C ProgramsLearn C ProgrammingNumber System You can …

C Program to find whether the given year is leap or not.

A leap year has 366 days instead of 365, with February 29 as the extra day. The Gregorian calendar uses a four-part rule to decide whether a year is a leap year. This rule is one of the most commonly tested C interview questions because it requires a compound conditional with exactly the right operator …

C Program to Generate N Fibonacci Terms Using Array

The Fibonacci sequence starts with 0 and 1; each subsequent term is the sum of the two that precede it: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, … This program generates the first n terms by storing them in an array, then printing the full sequence. Using an array — rather than …

C Program to find whether the given character is Vowel or Consonant

The five English vowels are: a, e, i, o, u (both upper and lowercase). Every other alphabetic character is a consonant. Non-alphabetic characters (digits, punctuation, spaces) are neither vowel nor consonant. This program uses the <ctype.h> functions isalpha() and tolower() for clean, case-insensitive classification. The original post used a Gist shortcode ([gist id=”7112441″]) that no …