Bhanu Priya has Published 1449 Articles

What are the limitations of array in C language?

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:49:17

12K+ Views

Arrays are a kind of data structure that can store a fixed-size sequential collection of elements of the same type.An array is used to store a collection of data, but it is often more useful to think of an array as a collection of variables of the same type.LimitationsThe limitations ... Read More

How communication among functions is established in C language?

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:45:24

737 Views

Functions communicate among themselves with the help of arguments and return value.Farm of ‘C’ function is as follows −return-datatype function name (argument list){    local variable declarations;    executable statements(s);    return (expression); }For example, void mul (int x, int y){    int p;    p=x*y;    printf("product = %d”, ... Read More

Explain top-down design and structure chart of function in C language

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:43:10

2K+ Views

A function is a self-contained block that carries out a specific well defined task.Advantages of functions in C language include −Reusability.The length of the program can be reduced.It is easy to locate and find any faulty function.It facilitates top-down modular programming.Top down design and structure chartsIt is a problem solving ... Read More

How floats are stored in C compiler?

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:41:56

853 Views

In C programming language, float is a short term for floating point.Floating point numbers are generally represented in the form of Institute of Electrical and Electronics Engineers (IEEE) format.The IEEE format uses a sign bit, a mantissa and an exponent for representing the power of 2.The sign bit denotes the ... Read More

How to print the range of numbers using C language?

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:41:01

2K+ Views

ProblemFor given number try to find the range in which that number exists.SolutionHere, we are learning how to find the ranges of a number.The logic that we apply to find range is −lower= (n/10) * 10; /*the arithmetic operators work from left to right*/ upper = lower+10;ExplanationLet number n=45Lower=(42/10)*10 // ... Read More

Finding sum of first and last digit using divide and modulo operator in C language

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:40:17

548 Views

ProblemWhat is the C program to obtain the sum of the first and last digit of the number, if a four-digit number is input through the keyboard?SolutionIn this program, we are taking a four-digit number at run time and trying to find the sum of first and last digit of ... Read More

Explain feof() function in C language with a program

Bhanu Priya

Bhanu Priya

Updated on 13-Mar-2021 11:18:45

461 Views

ProblemHow the C compiler detect that the file was reached the end for while reading? Explain with a program.Solutionfeof() is a file handling function in C language, which is used to find end of a file.The logic we used for finding end of file is as follows −fp = fopen ... Read More

How to pass the individual members as arguments to function using structure elements?

Bhanu Priya

Bhanu Priya

Updated on 11-Mar-2021 14:02:48

2K+ Views

There are three ways by which the values of structure can be transferred from one function to another. They are as follows −Passing individual members as arguments to function.Passing entire structure as an argument to function.Passing the address of structure as an argument to function.Now let’s see how to pass ... Read More

What are types of expressions evaluated in C Language?

Bhanu Priya

Bhanu Priya

Updated on 11-Mar-2021 10:17:10

877 Views

An expression is a combination of operators and operands.Operand is a data item in which operation is performed.An operator performs an operation on dataFor example; z = 3+2*1       z = 5Types of expressionsThe different types of expressions that are evaluated in C language are as follows −Primary expressions ... Read More

What are the different computer languages?

Bhanu Priya

Bhanu Priya

Updated on 11-Mar-2021 10:14:05

776 Views

The programming languages are used to give instructions to the computer in a language which a computer can understand.Computer languages are classified into three types as follows −Machine languagesSymbolic languagesHigh level languagesMachine languagesComputer is a machine. Since, its memory can store only 1’s and 0’s, instructions must be given to ... Read More

Advertisements