The scope of a variable x is the region of the program in which uses of x refers to its declaration. In C, all identifiers are lexically(or statically) scoped. Scoping in C Read more →
In this article, you will learn to find the quotient and remainder when an integer is divided by another integer. Examples : Input: A = 2, B = 7 Output: Quotient = Read more →
In this article, you will learn to swap two numbers in C programming. Examples : Input : x = 10, y = 20; Output : x = 20, y = 10 Input Read more →
C Program for Sum of digits of a given number. Examples : Input : 123 Output : 6 Input : 1995 Output : 24 Algorithm : To get sum of each digits Read more →
In this article, you’ll learn about strings in C programming. Strings are defined as an array of characters. The difference between a character array and a string is the string is terminated Read more →
In this article, you will learn to calculate the factorial of a number. Factorial of a non-negative integer, is multiplication of all integers smaller than or equal to n. For example factorial Read more →
In this article, you will learn to print the Fibonacci sequence of first n term. Fibonacci Series generates subsequent number by adding two previous numbers. The first two terms of the Fibonacci Read more →
In this article, you’ll learn about unions in C programming. More specifically, how to create unions, access its members and learn the differences between unions and structures. User defined data type : Read more →
In this example, you will learn to reverse the given number using these two methods. Examples : Input : 123 Output : 321 Input : 1995 Output : 5991 Approach used : Read more →
C Program to check whether the given integer is positive or negative. Examples : Input: 50 Output: Number is Positive. Input: -25 Output: Number is Negative. Input: 0 Output: Number is Positive Read more →