OSI Layers (Open Systems Interconnection) Physical Layer It deals with data at signals level electric impluses, radio , light waves. Needs support from hardware. This layer conveys the bit stream – electrical impulse, light or radio signal — through theContinue reading… Networks Concepts
Category: Placements
OS concepts
Virtual Memory Frames and their physical address Page Fault Thrashing
Avoid multiple inclusion of header file
Generally, a header (.h) file should have (A header file need not have a .h extension, its just a convention): 1. Macro definitions (preprocessor #defines). 2. Structure, union, and enumeration declarations. 3. Any typedef declarations. 4. External function declarations. 5.Continue reading… Avoid multiple inclusion of header file
Floating point representation, IEEE standard
IEEE Standard 754 floating point is the most common representation today for real numbers on computers, including Intel-based PC’s, Macintoshes, and most Unix platforms. IEEE floating point numbers have three basic components: the sign, the exponent, and the mantissa. TheContinue reading… Floating point representation, IEEE standard
Fibonacci numbers
f(n) = (1/sqrt(5)) * (((1+sqrt(5))/2) ^ n – ((1-sqrt(5))/2) ^ n) a Number N is fibacci number iff 5*N*N+4
Interview questions
Linked Lists Given only a pointer to a node to be deleted in a singly linked list, how do you delete it? Write a C program to implement a Generic Linked List. How would you detect a loop in aContinue reading… Interview questions
Bit wise operators
Bit wise operators and % operator cannot be applied to float fmod() is to find modulus for float as % is for int but it needs math.h; This can be used to detect whether a given number is an integerContinue reading… Bit wise operators
General C points
Unary + is the only dummy operator in C, you can just ignore this operator. i = – -1
scope of variables
labels (ex. goto ) have functions as scope. Labels which are outside the functions are not visible to this statement and cause compilation error.
Representation of negative numbers
main(){ printf(“%x”,-1