This document provides 50 interview questions on C programming language organized into 5 chapters: Variables & Control Flow, Operators, Constants & Structures, Functions, Pointers, and Programs. It aims to help both freshers and experienced programmers quickly brush up on basic C concepts commonly asked during job interviews at top companies. Each question is accompanied by a detailed answer along with code examples where applicable. Feedback is welcomed to be sent to the publisher.
This document provides an overview of fundamental concepts in C programming language including header files, character sets, tokens, keywords, identifiers, variables, constants, operators, data types, and control structures. Header files contain predefined standard library functions that are included using directives like #include<stdio.h>. C has 32 reserved keywords that cannot be used as identifiers. Variables are used to store and manipulate data in a program. Constants represent fixed values like integers, characters, and floating-point numbers. Operators perform operations on variables and constants. Data types specify the type and size of a variable. Control structures like if-else and loops are used to control the flow of a program.
This document discusses pointers in C programming. It defines pointers as memory variables that store memory addresses. It describes how pointers are declared using an asterisk and how they can be initialized to point to other variables by using the address-of operator. The document also discusses how pointers can be dereferenced using the indirection operator to access the value of the variable being pointed to. It provides examples of using pointers to pass values between functions and to access array elements.
Many times you might have wondered about all the complex and strange syntaxes of functions, variables and pointers in c. But these declarations are not as complex as it looks at first. When you know where to look and how to look, reading these syntaxes would become a piece of cake. Just see this presentation and you will find it very easy to read all the complexities in c.
The document discusses top-down design and functions in C programming. It defines top-down design as breaking a large problem down into smaller, more manageable parts or modules. A C program uses functions to implement top-down design, with each function representing a module. The key aspects covered include function declaration, definition, parameters, return values, and recursion. Functions are classified based on whether they return a value and if they accept parameters. Examples demonstrate different types of functions and how to write recursive functions.
This document provides an overview of the C programming language, including:
- Why software is needed for embedded systems and choosing an appropriate programming language
- Key features of C like being easier/faster to develop with, portability, and efficient pointer usage
- Differences between embedded C and desktop C like writing low-level and inline assembly code
- The structure of a basic C program and a "Hello, World!" example
- C programming basics like constants, variables, data types, and arithmetic, relational, logical, and bitwise operators
- Control flow statements in C like if, if/else, and switch
Python Session - 4
if
nested-if
if-else
elif (else if)
for loop (for iterating_var in sequence: )
while loop
break
continnue
pass
What is a function in Python?
Types of Functions
How to Define & Call Function
Scope and Lifetime of variables
lambda functions(anonymous functions)
This document provides an introduction to the C programming language, covering its history, uses, basic syntax, program structure, data types, variables, operators, and preprocessors. C was created in the 1970s by Dennis Ritchie at Bell Labs to develop the UNIX operating system. It is a general purpose, high-level language that produces efficient, structured programs and can handle both high-level and low-level activities. C is commonly used for operating systems, compilers, databases, and other modern programs. The document outlines the basic components needed to write C programs, including a compiler to translate human-readable source code into machine-executable code.
This document discusses pointers in C including pointer to arrays, pointers with unknown types, passing pointers by reference, pointers to pointers, NULL and unassigned pointers, pointers to functions, pointer tricks with operator precedence and associativity, reading bytes from data streams, pointers with constants, and modularity. The document is authored by ENG. Keroles Shenouda and provides a link to a Facebook group on embedded systems.
The document outlines the course content for a C++ introductory course, including introductions to OOP concepts like classes and objects, pointers, functions, inheritance, and polymorphism. It also covers basic C++ programming concepts like I/O, data types, operators, and data structures. The course aims to provide students with fundamental C++ programming skills through explanations and examples of key C++ features.
The document discusses various concepts related to strings in C programming language. It defines fixed length and variable length strings. For variable length strings, it explains length controlled and delimited strings. It describes how strings are stored and manipulated in C using character arrays terminated by a null character. The document also summarizes various string manipulation functions like string length, copy, compare, concatenate etc available in C standard library.
This document provides an introduction to C++ programming, covering key concepts like characters, tokens, keywords, identifiers, literals, operators, I/O streams, variables, comments, and common errors. It explains that Bjarne Stroustrup extended C to create C++, adding object-oriented features from Simula. The main components discussed are the building blocks of any C++ program - characters, tokens, data types, and basic input/output operations.
The document discusses definitions of functional programming from multiple sources. Functional programming is defined as programming using only pure functions and immutable values. A pure function is one that depends solely on its input parameters and algorithm to produce output, without side effects like modifying external state or performing I/O. Pure functions have properties of being total, deterministic, and inculpable/having no side effects. Functional programming involves writing programs as compositions of pure functions.
The document discusses templates in C++. It explains that templates allow functions and classes to work with different data types. Templates for functions are defined using a template prefix with type parameters, like <class T>. This allows a single function definition to handle multiple types. Similarly, class templates allow class definitions to work for multiple types. Examples show template functions for swapping values and sorting arrays, as well as a template Pair class to hold two values of the same type.
This document provides an overview of key concepts in C programming including identifiers, keywords, data types, operators, control statements, and functions for controlling program flow. It discusses identifiers and keywords rules. It also covers basic data types and different operators used in C. The document explains various control statements like if-else, switch case, for, while, do-while loops. It provides examples of using conditional operators and break and continue statements. Finally, it discusses nested loops and references additional resources to learn C programming.
This document provides an introduction to the C++ programming language. It discusses that C++ was developed in 1979 as an extension of C and is an object-oriented language. It then defines various C++ concepts such as tokens, data types, variables, constants, functions, arrays, structures, and input/output streams. It provides examples of how to declare and use these different programming elements in C++ code. The document serves as a high-level overview of fundamental C++ concepts for someone new to the language.
In this PPT you learn some basic terminology and basic concept of Python which is a pillar of python programming.So learn Python programming by these PPT.
You get a new presentation every Sunday at 10 AM.
This is Work-In-Progress. Developing a series of lectures on C++0x. This will augment my presentations on C++ and Design Pattern. First trial run was done at Interra, Noida in 2009
The document provides an overview of the C programming language. It discusses that C was developed at Bell Labs in the 1970s and is a general purpose language closely associated with UNIX. It then covers C's character set, keywords, basic program structure including header files and library functions, data types, variables, constants, and provides a simple "Hello World" example program.
This document discusses functions and modularity in C programming. It covers defining functions with parameters and return types, calling functions and passing arguments, common errors, and standard library functions for math, input/output, character processing and conversions. A case study demonstrates calculating age norms using functions.
This document provides an overview of programming languages and their classification. It discusses machine language, assembly language, and high-level languages. Machine language is directly understood by computers as binary code. Assembly language uses mnemonics instead of binary and requires an assembler. High-level languages like C use familiar syntax and require compilers or interpreters to convert code to machine language. C was created in 1972 and features portability, structured programming, and supports various data types. The document also covers C language elements like variables, constants, keywords, operators, and input/output functions.
The document discusses templates in C++. It explains that templates allow functions and classes to work with different data types through type parameters. It provides examples of template functions like swap_values that can swap values of any type. It also demonstrates a template class Pair that can hold two values of the same type. The document discusses how to define template functions and classes as well as how to declare and use objects based on template classes.
A function provides a convenient way of packaging a computational recipe, so that it can be used as often as required. A function definition consists of two parts: interface and body. The interface of a function (also called its prototype) specifies how it may be used. It consists of three entities:
The function name. This is simply a unique identifier.
The function parameters (also called its signature). This is a set of zero or more typed identifiers used for passing values to and from the function.
The function return type. This specifies the type of value the function returns. A function which returns nothing should have the return type void.
The body of a function contains the computational steps (statements) that comprise the function.
Functions allow programmers to organize code into reusable units and divide large programs into smaller, more manageable parts. The document discusses key concepts related to functions in Python like defining and calling user-defined functions, passing arguments, scope, and recursion. It provides examples of different types of functions and how concepts like mutability impact parameter passing. Functions are a fundamental part of modular and readable program design.
The document discusses user-defined functions in C++. It explains that a function allows structuring programs in a modular way by grouping statements that are executed when the function is called. The format of a function includes its return type, name, parameters, and function body enclosed in curly braces. Functions can be called by passing arguments, which are copied to the function's local parameter variables. Functions can return a single value. Function prototypes declare a function's interface without defining its body, allowing a function to be called before it is defined. Arguments can be passed by value, where copies are passed, or by reference, where the function can modify the original variables. Arrays can be passed to functions by only passing the array name
Python Session - 4
if
nested-if
if-else
elif (else if)
for loop (for iterating_var in sequence: )
while loop
break
continnue
pass
What is a function in Python?
Types of Functions
How to Define & Call Function
Scope and Lifetime of variables
lambda functions(anonymous functions)
This document provides an introduction to the C programming language, covering its history, uses, basic syntax, program structure, data types, variables, operators, and preprocessors. C was created in the 1970s by Dennis Ritchie at Bell Labs to develop the UNIX operating system. It is a general purpose, high-level language that produces efficient, structured programs and can handle both high-level and low-level activities. C is commonly used for operating systems, compilers, databases, and other modern programs. The document outlines the basic components needed to write C programs, including a compiler to translate human-readable source code into machine-executable code.
This document discusses pointers in C including pointer to arrays, pointers with unknown types, passing pointers by reference, pointers to pointers, NULL and unassigned pointers, pointers to functions, pointer tricks with operator precedence and associativity, reading bytes from data streams, pointers with constants, and modularity. The document is authored by ENG. Keroles Shenouda and provides a link to a Facebook group on embedded systems.
The document outlines the course content for a C++ introductory course, including introductions to OOP concepts like classes and objects, pointers, functions, inheritance, and polymorphism. It also covers basic C++ programming concepts like I/O, data types, operators, and data structures. The course aims to provide students with fundamental C++ programming skills through explanations and examples of key C++ features.
The document discusses various concepts related to strings in C programming language. It defines fixed length and variable length strings. For variable length strings, it explains length controlled and delimited strings. It describes how strings are stored and manipulated in C using character arrays terminated by a null character. The document also summarizes various string manipulation functions like string length, copy, compare, concatenate etc available in C standard library.
This document provides an introduction to C++ programming, covering key concepts like characters, tokens, keywords, identifiers, literals, operators, I/O streams, variables, comments, and common errors. It explains that Bjarne Stroustrup extended C to create C++, adding object-oriented features from Simula. The main components discussed are the building blocks of any C++ program - characters, tokens, data types, and basic input/output operations.
The document discusses definitions of functional programming from multiple sources. Functional programming is defined as programming using only pure functions and immutable values. A pure function is one that depends solely on its input parameters and algorithm to produce output, without side effects like modifying external state or performing I/O. Pure functions have properties of being total, deterministic, and inculpable/having no side effects. Functional programming involves writing programs as compositions of pure functions.
The document discusses templates in C++. It explains that templates allow functions and classes to work with different data types. Templates for functions are defined using a template prefix with type parameters, like <class T>. This allows a single function definition to handle multiple types. Similarly, class templates allow class definitions to work for multiple types. Examples show template functions for swapping values and sorting arrays, as well as a template Pair class to hold two values of the same type.
This document provides an overview of key concepts in C programming including identifiers, keywords, data types, operators, control statements, and functions for controlling program flow. It discusses identifiers and keywords rules. It also covers basic data types and different operators used in C. The document explains various control statements like if-else, switch case, for, while, do-while loops. It provides examples of using conditional operators and break and continue statements. Finally, it discusses nested loops and references additional resources to learn C programming.
This document provides an introduction to the C++ programming language. It discusses that C++ was developed in 1979 as an extension of C and is an object-oriented language. It then defines various C++ concepts such as tokens, data types, variables, constants, functions, arrays, structures, and input/output streams. It provides examples of how to declare and use these different programming elements in C++ code. The document serves as a high-level overview of fundamental C++ concepts for someone new to the language.
In this PPT you learn some basic terminology and basic concept of Python which is a pillar of python programming.So learn Python programming by these PPT.
You get a new presentation every Sunday at 10 AM.
This is Work-In-Progress. Developing a series of lectures on C++0x. This will augment my presentations on C++ and Design Pattern. First trial run was done at Interra, Noida in 2009
The document provides an overview of the C programming language. It discusses that C was developed at Bell Labs in the 1970s and is a general purpose language closely associated with UNIX. It then covers C's character set, keywords, basic program structure including header files and library functions, data types, variables, constants, and provides a simple "Hello World" example program.
This document discusses functions and modularity in C programming. It covers defining functions with parameters and return types, calling functions and passing arguments, common errors, and standard library functions for math, input/output, character processing and conversions. A case study demonstrates calculating age norms using functions.
This document provides an overview of programming languages and their classification. It discusses machine language, assembly language, and high-level languages. Machine language is directly understood by computers as binary code. Assembly language uses mnemonics instead of binary and requires an assembler. High-level languages like C use familiar syntax and require compilers or interpreters to convert code to machine language. C was created in 1972 and features portability, structured programming, and supports various data types. The document also covers C language elements like variables, constants, keywords, operators, and input/output functions.
The document discusses templates in C++. It explains that templates allow functions and classes to work with different data types through type parameters. It provides examples of template functions like swap_values that can swap values of any type. It also demonstrates a template class Pair that can hold two values of the same type. The document discusses how to define template functions and classes as well as how to declare and use objects based on template classes.
A function provides a convenient way of packaging a computational recipe, so that it can be used as often as required. A function definition consists of two parts: interface and body. The interface of a function (also called its prototype) specifies how it may be used. It consists of three entities:
The function name. This is simply a unique identifier.
The function parameters (also called its signature). This is a set of zero or more typed identifiers used for passing values to and from the function.
The function return type. This specifies the type of value the function returns. A function which returns nothing should have the return type void.
The body of a function contains the computational steps (statements) that comprise the function.
Functions allow programmers to organize code into reusable units and divide large programs into smaller, more manageable parts. The document discusses key concepts related to functions in Python like defining and calling user-defined functions, passing arguments, scope, and recursion. It provides examples of different types of functions and how concepts like mutability impact parameter passing. Functions are a fundamental part of modular and readable program design.
The document discusses user-defined functions in C++. It explains that a function allows structuring programs in a modular way by grouping statements that are executed when the function is called. The format of a function includes its return type, name, parameters, and function body enclosed in curly braces. Functions can be called by passing arguments, which are copied to the function's local parameter variables. Functions can return a single value. Function prototypes declare a function's interface without defining its body, allowing a function to be called before it is defined. Arguments can be passed by value, where copies are passed, or by reference, where the function can modify the original variables. Arrays can be passed to functions by only passing the array name
Introduction to C Language - Version 1.0 by Mark John LadoMark John Lado, MIT
The C programming language is a general-purpose, high – level language (generally denoted as structured language). C programming language was at first developed by Dennis M. Ritchie at At&T Bell Labs.
C is one of the most commonly used programming languages. It is simple and efficient therefore it becomes best among all. It is used in all extents of application, mainly in the software development.
Many software's & applications as well as the compilers for the other programming languages are written in C also Operating Systems like Unix, DOS and windows are written in C.
C has many powers, it is simple, stretchy and portable, and it can control system hardware easily. It is also one of the few languages to have an international standard, ANSI C.
This document provides an introduction to functions in C programming, including their motivation and benefits, syntax, components, operation, and data passing mechanisms. Functions allow code to be reused in different parts of a program or across multiple programs. They separate code into independent and reusable parts. The general syntax of a function includes its return type, name, parameters, and body. Functions are called by name with actual parameters passed in. They return control and any return value back to the calling function. Arrays can be passed to functions, which are effectively passed by reference so changes made in the function affect the original array.
Functions are the building blocks where every program activity occurs. They are self-contained program segments that carry out some specific, well-defined task. Every C program must have a function c functions list. c functions multiple choice questions
Storage class determines the accessibility and lifetime of a variable. The main storage classes in C++ are automatic, external, static, and register. Automatic variables are local to a function and are created and destroyed each time the function is called. External variables have global scope and persist for the lifetime of the program. Static variables also have local scope but retain their value between function calls.
Functions allow programmers to organize code into reusable blocks. A function performs a specific task and can accept input parameters and return an output. Functions make code more modular and easier to maintain. Functions are defined with a name, parameters, and body. They can be called from other parts of the code to execute their task. Parameters allow functions to accept input values, while return values allow functions to return output to the calling code. Functions can be called by passing arguments by value or reference. The document provides examples and explanations of different types of functions in C++ like inline functions, functions with default arguments, and global vs local variables.
This document discusses functions in C programming. It defines functions as a group of statements that perform a specific task and have a name. Main functions must be included in every C program as it is where program execution begins. Functions help facilitate modular programming by dividing programs into smaller parts. Functions can be user-defined or built-in library functions. Parameters can be passed to functions by value or by reference. Functions can call themselves through recursion. Variables have different storage classes like auto, register, static, and external that determine scope and lifetime.
We are one of the best embedded systems training institute for advance courses. We are the pioneer of the embedded system training in Pune & Pcmc with the expertise of over 16 years. we are working in the field training & development of embedded systems & currently we are also working on live projects as per the requirements of clients. though we provide many different courses & training in embedded all aim at giving good practical knowledge to students as well help them in their career.
The document discusses functions in C++. It begins by outlining key topics about functions that will be covered, such as function definitions, standard library functions, and function calls. It then provides details on defining and calling functions, including specifying return types, parameters, function prototypes, scope rules, and passing arguments by value or reference. The document also discusses local and global variables, function errors, and the differences between calling functions by value or reference.
The document contains questions and answers related to C programming. Some key points covered include:
1. Static variables retain their value between function calls or have internal linkage. The storage classes in C are automatic, static, and allocated.
2. Hashing is a technique to map data of arbitrary size to integers to facilitate fast searches. It involves using a hash function to condense data into a hash value which serves as an index into a hash table.
3. Include files can be nested and a header file can declare but not define a static variable, to avoid each source file having its own private copy.
Functions allow programmers to structure code into modular, reusable units. A function contains a block of code that is executed when the function is called. Functions take parameters as input and can return a value. The example function "addition" takes two integer parameters, adds them together, and returns the result. The main function calls addition, passing it the values 5 and 3, and stores the returned value 8 in the variable z. Functions help avoid duplicating code and make programs easier to design, understand, and maintain.
slide1: the content of functons
slide2: Introduction to function
slide3:function advantages
slide4 -5: types of functions
slide6: elements of user defined functions
1. The document discusses various concepts related to functions in C++ such as function prototypes, passing arguments by reference, default arguments, inline functions, function overloading, and friend functions.
2. It provides examples to explain concepts like passing arguments by reference allows altering the original variable values, a friend function can access private members of a class, and function overloading allows using the same function name for different tasks based on the argument types.
3. The key benefits of concepts like inline functions, passing by reference, and function overloading are also summarized.
The C programming language was developed in the 1970s and is widely used for system software and applications. The preprocessor modifies source code according to directives like #define and evaluates conditional compilation. It can create powerful macros and turn compiler features on/off. Static can retain value between function calls, make functions invisible to other files, or limit global variables to a file. C has automatic, static, and allocated storage classes. Hashing condenses data to an integer hash value for fast searching by using the value as an array index.
The document discusses various topics related to C programming language including data types in C, statements in C, the role of the preprocessor, ASCII character set, calculating volume and area of a sphere, reading and displaying student details, separating integral and fractional parts of a number, converting temperature between Fahrenheit and Celsius scales, operator precedence and associativity, and unary operators.
Multiple Choice Questions on JAVA (object oriented programming) bank 8 -- int...Kuntal Bhowmick
This document contains a bank of multiple choice questions about object oriented programming interfaces. It includes 21 questions about interfaces, each with 4 possible answers, followed by an explanation of the correct answer. The questions cover topics like how interfaces define methods without implementation, how classes implement interfaces, and how interfaces can extend other interfaces.
Multiple Choice Questions on JAVA (object oriented programming) bank 7 -- abs...Kuntal Bhowmick
The document contains a collection of multiple choice questions and answers about abstract classes in object-oriented programming. It includes 14 questions that test understanding of key concepts of abstract classes such as: when the abstract keyword is used, defining abstract methods, preventing instantiation of abstract classes, requiring subclasses to implement abstract methods, and preventing inheritance of classes. Each question is presented on an even page with its answer on the adjacent odd page.
Multiple Choice Questions on JAVA (object oriented programming) bank 6 -- inh...Kuntal Bhowmick
This document contains a 20 question multiple choice quiz about object oriented programming concepts related to inheritance. Each question is presented on an even page with the corresponding answer and explanation on the adjacent odd page. The quiz covers topics like superclass vs subclass, method overriding vs hiding, inheritance terminology in Java, and advantages/disadvantages of inheritance. The document instructs readers to first attempt each question before looking at the solution, and suggests viewing it in single page mode for clarity.
Multiple Choice Questions on JAVA (object oriented programming) bank 5 -- mem...Kuntal Bhowmick
This document contains 18 multiple choice questions about memory management in object-oriented programming. It provides the questions, possible answers, and explanations for the answers. The questions cover topics like garbage collection, heap fragmentation, advantages and disadvantages of garbage collection, the finalize() method, the this keyword, call by value vs call by reference, final variables and methods, static and nested classes.
Multiple Choice Questions on JAVA (object oriented programming) bank 4 -- loopsKuntal Bhowmick
1. The document contains 10 multiple choice questions about loops in object oriented programming.
2. Each question is presented on an even page with the solution provided on the adjacent odd page.
3. The questions cover topics like the while loop condition, do-while loop execution, for loop syntax, and the use of break and continue statements.
Multiple Choice Questions on JAVA (object oriented programming) bank 3 -- cla...Kuntal Bhowmick
This document contains a 17-page MCQ quiz on object-oriented programming concepts like classes, objects, and conditional statements. It includes 18 multiple choice questions about topics such as the difference between classes and objects, access specifiers, method overloading, constructors, and if statements. Each question is presented on an even page with the corresponding explanation and answer on the adjacent odd page. The document instructs readers to first attempt each question themselves before checking the solution.
Multiple Choice Questions on JAVA (object oriented programming) bank 2 -- bas...Kuntal Bhowmick
This document contains a 20-question multiple choice quiz on basic object-oriented programming concepts in Java. Each question is presented on an even page with possible answer options, while the corresponding solution and explanation is given on the adjacent odd page. The quiz covers fundamental topics like data types, access specifiers, inheritance, polymorphism, and more.
Multiple Choice Questions on JAVA (object oriented programming) bank 1 -- int...Kuntal Bhowmick
This document contains 20 multiple choice questions about object-oriented programming concepts. It provides the questions on adjacent even pages and the answers on adjacent odd pages. Some key concepts covered include encapsulation, inheritance, polymorphism, abstraction, and the differences between Java and C++.
Hashing notes data structures (HASHING AND HASH FUNCTIONS)Kuntal Bhowmick
A Hash table is a data structure used for storing and retrieving data very quickly. Insertion of data in the hash table is based on the key value. Hence every entry in the hash table is associated with some key.
HASHING AND HASH FUNCTIONS, HASH TABLE REPRESENTATION, HASH FUNCTION, TYPES OF HASH FUNCTIONS, COLLISION, COLLISION RESOLUTION, CHAINING, OPEN ADDRESSING – LINEAR PROBING, QUADRATIC PROBING, DOUBLE HASHING
introduction to E-commerce, Electronic commerce, EDI, CS802E,
e-commerce ,edi ,electronic data interchange ,traditional commerce ,buyer and seller ,origin of e-commerce ,business process ,impact of e-commerce ,value chain analysis ,company value chain ,case studies on e-commerce ,advantages of e-commerce ,disadvantages of e-commerce
The Bresenham's line algorithm uses integer calculations to draw lines on a raster display. It works by determining which pixel to plot next along the line based on a decision parameter. The parameter is initially calculated based on the line's slope and endpoints, and then updated as the algorithm moves from pixel to pixel. This allows the algorithm to avoid floating point arithmetic for improved efficiency.
- Java is a high-level programming language originally developed by Sun Microsystems and released in 1995. It runs on a variety of platforms such as Windows, Mac OS, and UNIX.
- The Java Virtual Machine (JVM) allows Java code to run on different platforms, as the bytecode is interpreted by the JVM rather than being compiled into platform-specific machine code.
- Some key features of Java include being object-oriented, platform independent, robust, interpreted, and multi-threaded.
This document provides an overview of object-oriented programming concepts in Java including encapsulation, inheritance, polymorphism, and abstraction. It also discusses key Java features like classes, interfaces, access modifiers, and differences between abstract classes and interfaces. Object-oriented principles like encapsulation, inheritance and polymorphism are explained along with examples. Common questions about Java concepts are also addressed at the end.
This document discusses various operating system concepts related to processes and threads. It defines key process terms like process state, process control block, and scheduling queues. It describes the different types of scheduling including long term, short term, and medium term scheduling. It also discusses process states like new, ready, running, waiting, and terminated. Process control blocks are described as storing information about the process state, program counter, CPU registers, scheduling, memory management, I/O status, and accounting. Scheduling queues include the job queue, ready queue, and device queues.
This document provides an overview of networking concepts including definitions of key terms like network, link, node, gateway, transmission media, protocols, error detection, and reliable data transmission protocols. It discusses the layers of the OSI model and responsibilities of each layer. Finally, it covers data link layer protocols, framing, flow control, error control techniques like ARQ, and reliable transmission protocols like stop-and-wait and sliding window protocols.
The document contains summaries of several C programming examples:
1. Programs to calculate the area and circumference of a circle, find simple interest, convert temperatures between Celsius and Fahrenheit, calculate subject marks and percentages, and calculate gross salary.
2. Additional programs demonstrate swapping values with and without a third variable, finding the greatest of three numbers, determining if a year is a leap year, and identifying integers as odd or even, positive or negative.
3. Further programs check if an integer is divisible by 5 and 11, compare two integers for equality, use a switch statement to print days of the week, and perform arithmetic operations using a switch case.
This document outlines 75 programming assignments covering fundamental C programming concepts like loops, arrays, pointers, strings, functions, structures, unions, and file handling. Students are instructed to only code the programs marked with asterisks in their lab assignment. The document provides the assignment questions, descriptions and page numbers. It also includes a link and QR code for online access to the file containing the full assignment details.
Passenger car unit (PCU) of a vehicle type depends on vehicular characteristics, stream characteristics, roadway characteristics, environmental factors, climate conditions and control conditions. Keeping in view various factors affecting PCU, a model was developed taking a volume to capacity ratio and percentage share of particular vehicle type as independent parameters. A microscopic traffic simulation model VISSIM has been used in present study for generating traffic flow data which some time very difficult to obtain from field survey. A comparison study was carried out with the purpose of verifying when the adaptive neuro-fuzzy inference system (ANFIS), artificial neural network (ANN) and multiple linear regression (MLR) models are appropriate for prediction of PCUs of different vehicle types. From the results observed that ANFIS model estimates were closer to the corresponding simulated PCU values compared to MLR and ANN models. It is concluded that the ANFIS model showed greater potential in predicting PCUs from v/c ratio and proportional share for all type of vehicles whereas MLR and ANN models did not perform well.
This paper proposes a shoulder inverse kinematics (IK) technique. Shoulder complex is comprised of the sternum, clavicle, ribs, scapula, humerus, and four joints.
Value Stream Mapping Worskshops for Intelligent Continuous SecurityMarc Hornbeek
This presentation provides detailed guidance and tools for conducting Current State and Future State Value Stream Mapping workshops for Intelligent Continuous Security.
Lidar for Autonomous Driving, LiDAR Mapping for Driverless Cars.pptxRishavKumar530754
LiDAR-Based System for Autonomous Cars
Autonomous Driving with LiDAR Tech
LiDAR Integration in Self-Driving Cars
Self-Driving Vehicles Using LiDAR
LiDAR Mapping for Driverless Cars
We introduce the Gaussian process (GP) modeling module developed within the UQLab software framework. The novel design of the GP-module aims at providing seamless integration of GP modeling into any uncertainty quantification workflow, as well as a standalone surrogate modeling tool. We first briefly present the key mathematical tools on the basis of GP modeling (a.k.a. Kriging), as well as the associated theoretical and computational framework. We then provide an extensive overview of the available features of the software and demonstrate its flexibility and user-friendliness. Finally, we showcase the usage and the performance of the software on several applications borrowed from different fields of engineering. These include a basic surrogate of a well-known analytical benchmark function; a hierarchical Kriging example applied to wind turbine aero-servo-elastic simulations and a more complex geotechnical example that requires a non-stationary, user-defined correlation function. The GP-module, like the rest of the scientific code that is shipped with UQLab, is open source (BSD license).
The Fluke 925 is a vane anemometer, a handheld device designed to measure wind speed, air flow (volume), and temperature. It features a separate sensor and display unit, allowing greater flexibility and ease of use in tight or hard-to-reach spaces. The Fluke 925 is particularly suitable for HVAC (heating, ventilation, and air conditioning) maintenance in both residential and commercial buildings, offering a durable and cost-effective solution for routine airflow diagnostics.
"Boiler Feed Pump (BFP): Working, Applications, Advantages, and Limitations E...Infopitaara
A Boiler Feed Pump (BFP) is a critical component in thermal power plants. It supplies high-pressure water (feedwater) to the boiler, ensuring continuous steam generation.
⚙️ How a Boiler Feed Pump Works
Water Collection:
Feedwater is collected from the deaerator or feedwater tank.
Pressurization:
The pump increases water pressure using multiple impellers/stages in centrifugal types.
Discharge to Boiler:
Pressurized water is then supplied to the boiler drum or economizer section, depending on design.
🌀 Types of Boiler Feed Pumps
Centrifugal Pumps (most common):
Multistage for higher pressure.
Used in large thermal power stations.
Positive Displacement Pumps (less common):
For smaller or specific applications.
Precise flow control but less efficient for large volumes.
🛠️ Key Operations and Controls
Recirculation Line: Protects the pump from overheating at low flow.
Throttle Valve: Regulates flow based on boiler demand.
Control System: Often automated via DCS/PLC for variable load conditions.
Sealing & Cooling Systems: Prevent leakage and maintain pump health.
⚠️ Common BFP Issues
Cavitation due to low NPSH (Net Positive Suction Head).
Seal or bearing failure.
Overheating from improper flow or recirculation.
Analysis of reinforced concrete deep beam is based on simplified approximate method due to the complexity of the exact analysis. The complexity is due to a number of parameters affecting its response. To evaluate some of this parameters, finite element study of the structural behavior of the reinforced self-compacting concrete deep beam was carried out using Abaqus finite element modeling tool. The model was validated against experimental data from the literature. The parametric effects of varied concrete compressive strength, vertical web reinforcement ratio and horizontal web reinforcement ratio on the beam were tested on eight (8) different specimens under four points loads. The results of the validation work showed good agreement with the experimental studies. The parametric study revealed that the concrete compressive strength most significantly influenced the specimens’ response with the average of 41.1% and 49 % increment in the diagonal cracking and ultimate load respectively due to doubling of concrete compressive strength. Although the increase in horizontal web reinforcement ratio from 0.31 % to 0.63 % lead to average of 6.24 % increment on the diagonal cracking load, it does not influence the ultimate strength and the load-deflection response of the beams. Similar variation in vertical web reinforcement ratio leads to an average of 2.4 % and 15 % increment in cracking and ultimate load respectively with no appreciable effect on the load-deflection response.
Sorting Order and Stability in Sorting.
Concept of Internal and External Sorting.
Bubble Sort,
Insertion Sort,
Selection Sort,
Quick Sort and
Merge Sort,
Radix Sort, and
Shell Sort,
External Sorting, Time complexity analysis of Sorting Algorithms.
Raish Khanji GTU 8th sem Internship Report.pdfRaishKhanji
This report details the practical experiences gained during an internship at Indo German Tool
Room, Ahmedabad. The internship provided hands-on training in various manufacturing technologies, encompassing both conventional and advanced techniques. Significant emphasis was placed on machining processes, including operation and fundamental
understanding of lathe and milling machines. Furthermore, the internship incorporated
modern welding technology, notably through the application of an Augmented Reality (AR)
simulator, offering a safe and effective environment for skill development. Exposure to
industrial automation was achieved through practical exercises in Programmable Logic Controllers (PLCs) using Siemens TIA software and direct operation of industrial robots
utilizing teach pendants. The principles and practical aspects of Computer Numerical Control
(CNC) technology were also explored. Complementing these manufacturing processes, the
internship included extensive application of SolidWorks software for design and modeling tasks. This comprehensive practical training has provided a foundational understanding of
key aspects of modern manufacturing and design, enhancing the technical proficiency and readiness for future engineering endeavors.
its all about Artificial Intelligence(Ai) and Machine Learning and not on advanced level you can study before the exam or can check for some information on Ai for project
1. What is a pointer on pointer?
It’s a pointer variable which can hold the address of another pointer variable. It de-refers twice to
point to the data held by the designated pointer variable.
Eg: int x = 5, *p=&x, **q=&p;
Therefore ‘x’ can be accessed by **q.
Distinguish between malloc() & calloc() memory allocation.
Both allocates memory from heap area/dynamic memory. By default calloc fills the allocated
memory with 0’s.
What is keyword auto for?
By default every local variable of the function is automatic (auto). In the below function both the
variables ‘i’ and ‘j’ are automatic variables.
void f() {
int i;
auto int j;
}
NOTE − A global variable can’t be an automatic variable.
What are the valid places for the keyword break to appear.
Break can appear only with in the looping control and switch statement. The purpose of the break
is to bring the control out from the said blocks.
Explain the syntax for for loop.
for(expression-1;expression-2;expression-3) {
//set of statements
}
When control reaches for expression-1 is executed first. Then following expression-2, and if
expression-2 evaluates to non-zero ‘set of statements’ and expression-3 is executed, follows
expression-2.
What is difference between including the header file with-in angular braces < > and double
quotes “ “
If a header file is included with in < > then the compiler searches for the particular header file
only with in the built in include path. If a header file is included with in “ “, then the compiler
searches for the particular header file first in the current working directory, if not found then in
the built in include path.
How a negative integer is stored. What is a static variable?
A static local variables retains its value between the function call and the default value is 0. The
following function will print 1 2 3 if called thrice.
void f() {
static int i;
++i;
printf(“%d “,i);
}
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
2. If a global variable is static then its visibility is limited to the same source code.
What is a NULL pointer?
A pointer pointing to nothing is called so. Eg: char *p=NULL;
What is the purpose of extern storage specifier?
Used to resolve the scope of global symbol.
Eg:
main() {
extern int i;
Printf(“%d”,i);
}
int i = 20;
Explain the purpose of the function sprintf().
Prints the formatted output onto the character array.
What is the meaning of base address of the array?
The starting address of the array is called as the base address of the array.
When should we use the register storage specifier?
If a variable is used most frequently then it should be declared using register storage specifier,
then possibly the compiler gives CPU register for its storage to speed up the look up of the
variable.
S++ or S = S+1, which can be recommended to increment the value by 1 and why?
S++, as it is single machine instruction (INC) internally.
What is a dangling pointer?
A pointer initially holding valid address, but later the held address is released or freed. Then such
a pointer is called as dangling pointer.
What is the purpose of the keyword typedef?
It is used to alias the existing type. Also used to simplify the complex declaration of the type.
What is lvalue and rvalue?
The expression appearing on right side of the assignment operator is called as rvalue. Rvalue is
assigned to lvalue, which appears on left side of the assignment operator. The lvalue should
designate to a variable not a constant.
What is the difference between actual and formal parameters?
The parameters sent to the function at calling end are called as actual parameters while at the
receiving of the function definition called as formal parameters.
Can a program be compiled without main() function?
Yes, it can be but cannot be executed, as the execution requires main() function definition.
What is the advantage of declaring void pointers?
When we do not know what type of the memory address the pointer variable is going to hold,
then we declare a void pointer for such.
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
3. Where an automatic variable is stored?
Every local variable by default being an auto variable is stored in stack memory.
What is a nested structure?
A structure containing an element of another structure as its member is referred so.
What is the difference between variable declaration and variable definition?
Declaration associates type to the variable whereas definition gives the value to the variable.
What is a self-referential structure?
A structure containing the same structure pointer variable as its element is called as self-
referential structure.
Does a built-in header file contains built-in function definition?
No, the header file only declares function. The definition is in library which is linked by the
linker.
Explain modular programming.
Dividing the program in to sub programs (modules/function) to achieve the given task is modular
approach. More generic functions definition gives the ability to re-use the functions, such as
built-in library functions.
What is a token?
A C program consists of various tokens and a token is either a keyword, an identifier, a constant,
a string literal, or a symbol.
What is a preprocessor?
Preprocessor is a directive to the compiler to perform certain things before the actual compilation
process begins.
Explain the use of %i format specifier w.r.t scanf().
Can be used to input integer in all the supported format.
How can you print a (backslash) using any of the printf() family of functions.
Escape it using (backslash).
Does a break is required by default case in switch statement?
Yes, if it is not appearing as the last case and if we do not want the control to flow to the
following case after default if any.
When to user -> (arrow) operator.
If the structure/union variable is a pointer variable, to access structure/union elements the arrow
operator is used.
What are bit fields?
We can create integer structure members of differing size apart from non-standard size using bit
fields. Such structure size is automatically adjusted with the multiple of integer size of the
machine.
What are command line arguments?
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
4. The arguments which we pass to the main() function while executing the program are called as
command line arguments. The parameters are always strings held in the second argument (below
in args) of the function which is array of character pointers. First argument represents the count
of arguments (below in count) and updated automatically by operating system.
main( int count, char *args[]) {
}
What are the different ways of passing parameters to the functions? Which to use when?
Call by value − We send only values to the function as parameters. We choose this if we
do not want the actual parameters to be modified with formal parameters but just used.
Call by reference − We send address of the actual parameters instead of values. We
choose this if we do want the actual parameters to be modified with formal parameters.
What is the purpose of built-in stricmp() function.
It compares two strings by ignoring the case.
Describe the file opening mode “w+”.
Opens a file both for reading and writing. If a file is not existing it creates one, else if the file is
existing it will be over written.
Where the address of operator (&) cannot be used?
It cannot be used on constants.
It cannot be used on variable which are declared using register storage class.
Is FILE a built-in data type?
No, it is a structure defined in stdio.h.
What is reminder for 5.0 % 2?
Error, It is invalid that either of the operands for the modulus operator (%) is a real number.
How many operators are there under the category of ternary operators?
There is only one operator and is conditional operator (? : ).
Which key word is used to perform unconditional branching?
goto
What is a pointer to a function? Give the general syntax for the same.
A pointer holding the reference of the function is called pointer to a function. In general it is
declared as follows.
T (*fun_ptr) (T1,T2…); Where T is any date type.
Once fun_ptr refers a function the same can be invoked using the pointer as follows.
fun_ptr();
[Or]
(*fun_ptr)();
Explain the use of comma operator (,).
Comma operator can be used to separate two or more expressions.
Eg: printf(“hi”) , printf(“Hello”);
What is a NULL statement?
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
5. A null statement is no executable statements such as ; (semicolon).
Eg: int count = 0;
while( ++count<=10 ) ;
Above does nothing 10 times.
What is a static function?
A function’s definition prefixed with static keyword is called as a static function. You would
make a function static if it should be called only within the same source code.
Which compiler switch to be used for compiling the programs using math library with gcc
compiler?
Opiton –lm to be used as > gcc –lm <file.c>
Which operator is used to continue the definition of macro in the next line?
Backward slash () is used.
E.g. #define MESSAGE "Hi,
Welcome to C"
Which operator is used to receive the variable number of arguments for a function?
Ellipses (…) is used for the same. A general function definition looks as follows
void f(int k,…) {
}
What is the problem with the following coding snippet?
char *s1 = "hello",*s2 = "welcome";
strcat(s1,s2);
s1 points to a string constant and cannot be altered.
Which built-in library function can be used to re-size the allocated dynamic memory?
realloc().
Define an array.
Array is collection of similar data items under a common name.
What are enumerations?
Enumerations are list of integer constants with name. Enumerators are defined with the keyword
enum.
Which built-in function can be used to move the file pointer internally?
fseek()
What is a variable?
A variable is the name storage.
Who designed C programming language?
Dennis M Ritchie.
C is successor of which programming language?
B
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
6. What is the full form of ANSI?
American National Standards Institute.
Which operator can be used to determine the size of a data type or variable?
sizeof
Can we assign a float variable to a long integer variable?
Yes, with loss of fractional part.
Is 068 a valid octal number?
No, it contains invalid octal digits.
What it the return value of a relational operator if it returns any?
Return a value 1 if the relation between the expressions is true, else 0.
How does bitwise operator XOR works.
If both the corresponding bits are same it gives 0 else 1.
What is an infinite loop?
A loop executing repeatedly as the loop-expression always evaluates to true such as
while(0 == 0) {
}
Can variables belonging to different scope have same name? If so show an example.
Variables belonging to different scope can have same name as in the following code snippet.
int var;
void f() {
int var;
}
main() {
int var;
}
What is the default value of local and global variables?
Local variables get garbage value and global variables get a value 0 by default.
Can a pointer access the array?
Pointer by holding array’s base address can access the array.
What are valid operations on pointers?
The only two permitted operations on pointers are
Comparision ii) Addition/Substraction (excluding void pointers)
What is a string length?
It is the count of character excluding the ‘0’ character.
What is the built-in function to append one string to another?
strcat() form the header string.h
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
7. Which operator can be used to access union elements if union variable is a pointer
variable?
Arrow (->) operator.
Explain about ‘stdin’.
stdin in a pointer variable which is by default opened for standard input device.
Name a function which can be used to close the file stream.
fclose().
What is the purpose of #undef preprocessor?
It be used to undefine an existing macro definition.
Define a structure.
A structure can be defined of collection of heterogeneous data items.
Name the predefined macro which be used to determine whether your compiler is ANSI standard
or not?
__STDC__
What is typecasting?
Typecasting is a way to convert a variable/constant from one type to another type.
What is recursion?
Function calling itself is called as recursion.
Which function can be used to release the dynamic allocated memory?
free().
What is the first string in the argument vector w.r.t command line arguments?
Program name.
How can we determine whether a file is successfully opened or not using fopen() function?
On failure fopen() returns NULL, otherwise opened successfully.
What is the output file generated by the linker.
Linker generates the executable file.
What is the maximum length of an identifier?
Ideally it is 32 characters and also implementation dependent.
What is the default function call method?
By default the functions are called by value.
Functions must and should be declared. Comment on this.
Function declaration is optional if the same is invoked after its definition.
When the macros gets expanded?
At the time of preprocessing.
Can a function return multiple values to the caller using return reserved word?
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)
8. No, only one value can be returned to the caller.
What is a constant pointer?
A pointer which is not allowed to be altered to hold another address after it is holding one.
To make pointer generic for which date type it need to be declared?
Void
Can the structure variable be initialized as soon as it is declared?
Yes, w.r.t the order of structure elements only.
Is there a way to compare two structure variables?
There is no such. We need to compare element by element of the structure variables.
Which built-in library function can be used to match a patter from the string?
Strstr()
What is difference between far and near pointers?
In first place they are non-standard keywords. A near pointer can access only 2^15 memory
space and far pointer can access 2^32 memory space. Both the keywords are implementation
specific and are non-standard.
Can we nest comments in a C code?
No, we cannot.
Which control loop is recommended if you have to execute set of statements for fixed
number of times?
for – Loop.
What is a constant?
A value which cannot be modified is called so. Such variables are qualified with the keyword
const.
Can we use just the tag name of structures to declare the variables for the same?
No, we need to use both the keyword ‘struct’ and the tag name.
Can the main() function left empty?
Yes, possibly the program doing nothing.
Can one function call another?
Yes, any user defined function can call any function.
Apart from Dennis Ritchie who the other person who contributed in design of C language.
Brain Kernighan
Prepared by Prof. Gunjan Mukherjee(MCA Dept,RERF)