Category: Embedded System
-
Stack implementation without pointer
Stack is a type of data structure, where data is stored in Last In First Out fashion. In embedded system there are different kind of stacks available. They are implemented in hardware and software. The hardware implementation of stack is faster than software stack; but the size of stack in hardware is limited. There are…
-
The command-line argument in C
Lets say if we want our program to work with other programs and other program call our program. Then just like how we provide arguments in function call; we can call our program and the arguments can be given using the command line. argc contains the number of argument passed to the main function. argv…
-
Union
Union is another user defined data type. The difference between union and struct is that; struct uses a contagious memory allocation for each individual item inside it; whereas union uses the size of biggest element for allocation of memory.
-
Struct
Variables are used for storage of individual data elements. But what if we want to group different data element and use them as a individual element. Nesting Struct is a way of creating more complex data structure.
-
First Program in C language
The very first program in every language is “Hello World”. You can compile this program very easily.