C programming is a widely used programming language. The document provides an overview of key concepts in C programming including variables, data types, operators, decision and loop control statements, functions, pointers, arrays, strings, structures, and input/output functions. It also provides examples to illustrate concepts like arrays, strings, functions, pointers, and structures. The main function is the entry point for all C programs where code execution begins.
This document provides an overview of C programming basics including character sets, tokens, keywords, variables, data types, and control statements in C language. Some key points include:
- The C character set includes lowercase/uppercase letters, digits, special characters, whitespace, and escape sequences.
- Tokens in C include operators, special symbols, string constants, identifiers, and keywords. There are 32 reserved keywords that should be in lowercase.
- Variables are named locations in memory that hold values. They are declared with a data type and initialized by assigning a value.
- C has primary data types like int, float, char, and double. Derived types include arrays, pointers, unions, structures,
This document discusses decision and loop control in C programming. It covers if, if-else, conditional operators, relational operators, logical operators, the conditional operator (? :) and various loops including while, do-while and for loops. Examples are provided to demonstrate the use of if/else, logical operators, conditional operators and while, do-while loops. Flowcharts are also included to illustrate program flow. The document is presented by Vinay Arora and covers basic conditional and loop control structures in C.
The document discusses the basics of C language including tokens, data types, constants, and variables. It covers keywords, identifiers, operators, and other tokens in C. It describes the basic integral and floating point data types like int, char, float, and double. It also discusses numerical, character, and string constants. Finally, it explains how to declare variables and the differences between global and local variables.
The document discusses input and output functions in C programming. It describes getchar() and putchar() for character input/output, printf() and scanf() for formatted input/output, and gets() and puts() for string input/output. It provides examples of using these functions to read input from the keyboard and display output to the screen.
This chapter discusses fundamental concepts of C programming language and basic input/output functions. It covers C development environment, C program structure including main functions and statements, basic data types, input/output functions like printf and scanf, and common programming errors.
The document discusses various operators and control structures in C language. It describes operator precedence and associativity. Some key operator types include arithmetic, relational, logical, and bitwise operators. It also covers various control structures like if-else, switch statements, and loops (for, while, do-while). If-else is used to execute code conditionally based on true/false evaluations. Switch allows executing code based on multiple conditions. Loops iterate code for a set number of times or until a condition becomes false.
1. There are two main ways to handle input-output in C - formatted functions like printf() and scanf() which require format specifiers, and unformatted functions like getchar() and putchar() which work only with characters.
2. Formatted functions allow formatting of different data types like integers, floats, and strings. Unformatted functions only work with characters.
3. Common formatted functions include printf() for output and scanf() for input. printf() outputs data according to format specifiers, while scanf() reads input and stores it in variables based on specifiers.
The document contains 40 multiple choice questions related to computer science class 12. It covers topics like variables, data types, operators, loops, functions, arrays and more. The questions test concepts like escape sequences, format specifiers, assignment operators, comments, input/output functions, and the difference between various loops in C programming language. It is a practice test to help students prepare for their computer science exam.
It is an attempt to make the students of IT understand the basics of programming in C in a simple and easy way. Send your feedback for rectification/further development.
Important C program of Balagurusamy BookAbir Hossain
This document contains summaries of multiple programming labs involving different programming concepts like functions, arrays, strings, conditionals, loops, etc. The labs cover basics like printing an address, calculating expressions, finding roots of equations, computing trigonometric functions; conditionals like determining if a number is even/odd, larger/smaller; functions including calculating factorial, power series, fibonacci series; arrays for storing student marks, vote counting; strings for manipulation and analysis.
Programming is an essential skill if you seek a career in software development, or in other fields of Coding. This fundamental of programming course is the first in the specialization for Introduction to Programming in C, but its lessons extend to any language you might want to study. This is because programming is primarily about solving a set of problems and writing the algorithm.
This document discusses using switch-case statements in C programming to perform mathematical operations. It provides the syntax for switch-case, an example of a program that takes two numbers and an operator as input to perform addition, subtraction, multiplication and division. The program is presented along with its flowchart and algorithm. The learning objectives are to write switch-case syntax, draw flowcharts, write algorithms and programs using switch-case statements.
This document provides an overview of the C programming language. It covers various C language concepts like data types, operators, control structures, arrays, strings, functions and more. The document is divided into 9 sections with each section covering a specific C concept. For example, section 1 provides an introduction to C including its history, the difference between compilers and interpreters. Section 2 covers data types, constants and variables in C. Section 3 discusses operators and expressions. Section 4 explains various control structures like if-else, switch case etc. Section 5 is about looping constructs like while, do-while and for loops. Section 6 demonstrates looping with patterns. Section 7 describes arrays in C including 1D and 2D arrays. Section 8 covers
The document discusses various C programming concepts including data types, variables, constants, and input/output functions. It covers fundamental data types like integers, floats, characters, and derived types like arrays, pointers, and structures. It also explains variable declaration syntax, integer and floating point input/output, and arithmetic, relational, logical, and conditional operators.
C is a middle-level general purpose programming language developed in 1972. It uses characters, keywords, variables, constants, data types, expressions and operators. Variables are named locations used to store and manipulate data during execution. C supports several data types including integer, float, character and others. Operators perform actions like arithmetic, relational, logical and bitwise operations on variables and constants.
Constants Variables Datatypes by Mrs. Sowmya JyothiSowmyaJyothi3
C provides various data types to store different types of data. The main data types are integer, float, double, and char. Variables are used to store and manipulate data in a program. Variables must be declared before use, specifying the data type. Constants are fixed values that don't change, and can be numeric, character, or string values. Symbolic constants can be defined to represent constant values used throughout a program. Input and output of data can be done using functions like scanf and printf.
This document provides instructions for writing a C program to count the vowels, consonants, digits, and whitespace in a string. It begins by explaining how to declare, initialize, read, and manipulate strings in C. It then presents the algorithm and full C program to iterate through a string, check each character, and increment the appropriate counter. The program takes a string as input and outputs the count of each type of character. Examples of additional string programs are provided for practice.
The document discusses C programming concepts related to decision control statements like if, if-else, else-if ladder, and nested if-else. It provides examples of code and flowcharts for programs using each type of decision statement to check conditions and display outputs. The document is divided into multiple sections for each decision statement type, with theory, an example program, inputs/outputs, and practice problems in each section.
This document contains notes from a lecture on C programming. It introduces basic C concepts like data types, operators, input/output functions, and provides examples of simple C programs. It also discusses compiling and executing C code, precedence rules for operators, and homework problems involving increment operators. The lecture aims to recap basic C knowledge and provide more in-depth coverage of topics like data types, arithmetic operations, and I/O functions.
The document discusses three-address code, which is an intermediate representation used in compilers. It describes three-address code as consisting of statements in the form of x := y op z, where x, y, and z are operands and op is an operator. There are several types of three-address statements including assignment, copy, jump, conditional jump, procedure calls, indexed assignments, and pointer assignments. Three-address code can be implemented using quadruples, triples, or indirect triples, which represent the statements using records with fields for operands and operators.
The document discusses input and output functions in C programming, specifically covering the printf and scanf functions. It explains how printf works by taking a format string and values to insert, and how scanf works by reading input according to a format string and storing the values in variables. Special format specifiers, escape sequences, and handling errors are also covered.
The document provides information on the C programming language. It discusses that C was developed by Dennis Ritchie at Bell Labs in 1972 and is a general purpose programming language well suited for business and scientific applications. It describes the basic structure of a C program including sections for links, definitions, variables, functions, and input/output statements. It also covers various C language concepts like data types, operators, decision making statements, looping statements, functions, and more.
pointer, structure ,union and intro to file handlingRai University
Pointers allow programs to store and pass around memory addresses. Pointers in C can point to primitive data types, arrays, structs, and other pointers. Declaring a pointer requires a * before the pointer name and specifying the type of data it will point to. The & operator returns the memory address of a variable, which can be stored in a pointer. The * operator dereferences a pointer to access the data being pointed to. Pointers enable functions to modify variables in the calling function and return multiple values. They also make structs more efficient to pass to functions. Care must be taken to avoid bugs from misusing pointers.
Este documento fornece um tutorial passo-a-passo para criar um jogo de palavras-cruzadas no LibreOffice Calc. Ele explica como formatar células, adicionar perguntas, proteger a planilha e editar o jogo de palavras-cruzadas. O objetivo é demonstrar como integrar as TICs em atividades educativas usando o editor de planilhas eletrônicas.
This document provides an operational assessment for Mantra-care, a plastic surgery clinic for men. It summarizes Mantra-care's marketing plan and economic analysis, outlines its objectives and strategies, and analyzes factors that could affect its output such as staff skill levels, processes, and resources. The assessment also examines Mantra-care's supply chain and potential problems and solutions related to capacity, quality, and achieving its strategic goals.
The document summarizes the construction of the Gautam Buddha International Circuit racing track in India. Key details include:
- Over 4 million cubic tons of earth was moved and 325,000 tons of asphalt was used to construct the 5.1 km track with 16 turns.
- Construction involved laying 5 layers of materials to support heavy racing cars at high speeds. A mixing plant 5 km away produced the asphalt.
- A main grandstand was built with 30m height, 138m length, 56 steel trusses weighing 40 tons each, and a 40m cantilever roof with 50,000 sqm of aluminum sheeting.
- Sophisticated safety barriers and 450
1. There are two main ways to handle input-output in C - formatted functions like printf() and scanf() which require format specifiers, and unformatted functions like getchar() and putchar() which work only with characters.
2. Formatted functions allow formatting of different data types like integers, floats, and strings. Unformatted functions only work with characters.
3. Common formatted functions include printf() for output and scanf() for input. printf() outputs data according to format specifiers, while scanf() reads input and stores it in variables based on specifiers.
The document contains 40 multiple choice questions related to computer science class 12. It covers topics like variables, data types, operators, loops, functions, arrays and more. The questions test concepts like escape sequences, format specifiers, assignment operators, comments, input/output functions, and the difference between various loops in C programming language. It is a practice test to help students prepare for their computer science exam.
It is an attempt to make the students of IT understand the basics of programming in C in a simple and easy way. Send your feedback for rectification/further development.
Important C program of Balagurusamy BookAbir Hossain
This document contains summaries of multiple programming labs involving different programming concepts like functions, arrays, strings, conditionals, loops, etc. The labs cover basics like printing an address, calculating expressions, finding roots of equations, computing trigonometric functions; conditionals like determining if a number is even/odd, larger/smaller; functions including calculating factorial, power series, fibonacci series; arrays for storing student marks, vote counting; strings for manipulation and analysis.
Programming is an essential skill if you seek a career in software development, or in other fields of Coding. This fundamental of programming course is the first in the specialization for Introduction to Programming in C, but its lessons extend to any language you might want to study. This is because programming is primarily about solving a set of problems and writing the algorithm.
This document discusses using switch-case statements in C programming to perform mathematical operations. It provides the syntax for switch-case, an example of a program that takes two numbers and an operator as input to perform addition, subtraction, multiplication and division. The program is presented along with its flowchart and algorithm. The learning objectives are to write switch-case syntax, draw flowcharts, write algorithms and programs using switch-case statements.
This document provides an overview of the C programming language. It covers various C language concepts like data types, operators, control structures, arrays, strings, functions and more. The document is divided into 9 sections with each section covering a specific C concept. For example, section 1 provides an introduction to C including its history, the difference between compilers and interpreters. Section 2 covers data types, constants and variables in C. Section 3 discusses operators and expressions. Section 4 explains various control structures like if-else, switch case etc. Section 5 is about looping constructs like while, do-while and for loops. Section 6 demonstrates looping with patterns. Section 7 describes arrays in C including 1D and 2D arrays. Section 8 covers
The document discusses various C programming concepts including data types, variables, constants, and input/output functions. It covers fundamental data types like integers, floats, characters, and derived types like arrays, pointers, and structures. It also explains variable declaration syntax, integer and floating point input/output, and arithmetic, relational, logical, and conditional operators.
C is a middle-level general purpose programming language developed in 1972. It uses characters, keywords, variables, constants, data types, expressions and operators. Variables are named locations used to store and manipulate data during execution. C supports several data types including integer, float, character and others. Operators perform actions like arithmetic, relational, logical and bitwise operations on variables and constants.
Constants Variables Datatypes by Mrs. Sowmya JyothiSowmyaJyothi3
C provides various data types to store different types of data. The main data types are integer, float, double, and char. Variables are used to store and manipulate data in a program. Variables must be declared before use, specifying the data type. Constants are fixed values that don't change, and can be numeric, character, or string values. Symbolic constants can be defined to represent constant values used throughout a program. Input and output of data can be done using functions like scanf and printf.
This document provides instructions for writing a C program to count the vowels, consonants, digits, and whitespace in a string. It begins by explaining how to declare, initialize, read, and manipulate strings in C. It then presents the algorithm and full C program to iterate through a string, check each character, and increment the appropriate counter. The program takes a string as input and outputs the count of each type of character. Examples of additional string programs are provided for practice.
The document discusses C programming concepts related to decision control statements like if, if-else, else-if ladder, and nested if-else. It provides examples of code and flowcharts for programs using each type of decision statement to check conditions and display outputs. The document is divided into multiple sections for each decision statement type, with theory, an example program, inputs/outputs, and practice problems in each section.
This document contains notes from a lecture on C programming. It introduces basic C concepts like data types, operators, input/output functions, and provides examples of simple C programs. It also discusses compiling and executing C code, precedence rules for operators, and homework problems involving increment operators. The lecture aims to recap basic C knowledge and provide more in-depth coverage of topics like data types, arithmetic operations, and I/O functions.
The document discusses three-address code, which is an intermediate representation used in compilers. It describes three-address code as consisting of statements in the form of x := y op z, where x, y, and z are operands and op is an operator. There are several types of three-address statements including assignment, copy, jump, conditional jump, procedure calls, indexed assignments, and pointer assignments. Three-address code can be implemented using quadruples, triples, or indirect triples, which represent the statements using records with fields for operands and operators.
The document discusses input and output functions in C programming, specifically covering the printf and scanf functions. It explains how printf works by taking a format string and values to insert, and how scanf works by reading input according to a format string and storing the values in variables. Special format specifiers, escape sequences, and handling errors are also covered.
The document provides information on the C programming language. It discusses that C was developed by Dennis Ritchie at Bell Labs in 1972 and is a general purpose programming language well suited for business and scientific applications. It describes the basic structure of a C program including sections for links, definitions, variables, functions, and input/output statements. It also covers various C language concepts like data types, operators, decision making statements, looping statements, functions, and more.
pointer, structure ,union and intro to file handlingRai University
Pointers allow programs to store and pass around memory addresses. Pointers in C can point to primitive data types, arrays, structs, and other pointers. Declaring a pointer requires a * before the pointer name and specifying the type of data it will point to. The & operator returns the memory address of a variable, which can be stored in a pointer. The * operator dereferences a pointer to access the data being pointed to. Pointers enable functions to modify variables in the calling function and return multiple values. They also make structs more efficient to pass to functions. Care must be taken to avoid bugs from misusing pointers.
Este documento fornece um tutorial passo-a-passo para criar um jogo de palavras-cruzadas no LibreOffice Calc. Ele explica como formatar células, adicionar perguntas, proteger a planilha e editar o jogo de palavras-cruzadas. O objetivo é demonstrar como integrar as TICs em atividades educativas usando o editor de planilhas eletrônicas.
This document provides an operational assessment for Mantra-care, a plastic surgery clinic for men. It summarizes Mantra-care's marketing plan and economic analysis, outlines its objectives and strategies, and analyzes factors that could affect its output such as staff skill levels, processes, and resources. The assessment also examines Mantra-care's supply chain and potential problems and solutions related to capacity, quality, and achieving its strategic goals.
The document summarizes the construction of the Gautam Buddha International Circuit racing track in India. Key details include:
- Over 4 million cubic tons of earth was moved and 325,000 tons of asphalt was used to construct the 5.1 km track with 16 turns.
- Construction involved laying 5 layers of materials to support heavy racing cars at high speeds. A mixing plant 5 km away produced the asphalt.
- A main grandstand was built with 30m height, 138m length, 56 steel trusses weighing 40 tons each, and a 40m cantilever roof with 50,000 sqm of aluminum sheeting.
- Sophisticated safety barriers and 450
This document provides an overview of GATI-KWE, a joint venture between Indian logistics company GATI and Japanese logistics company KWE. It summarizes GATI-KWE's services including express distribution, supply chain solutions, cold chain logistics, and freight forwarding. It also outlines the company's infrastructure, network reach, technology capabilities, and key clients. The document positions GATI-KWE as a leader in integrated logistics and express distribution across India and globally.
01 os pré-socráticos - coleção os pensadores (1996)Esdras Cardoso
Este documento fornece um resumo sobre os Pré-Socráticos, incluindo informações sobre os autores, tradutores e consultores envolvidos na publicação. Além disso, discute o surgimento da filosofia na Grécia antiga e a transição do mito para o pensamento racional, bem como a influência das epopéias de Homero na visão dos deuses naquela época.
O documento fornece instruções sobre como usar dicionários de forma eficaz, incluindo dominar a ordem alfabética, conhecer abreviaturas e a estrutura da informação. Também lista diferentes tipos de dicionários e fornece dicas sobre como procurar palavras rapidamente e entender as regras de apresentação.
Este documento discute as propriedades, processos de transformação, armazenamento e utilizações da madeira. Ele explica que a madeira pode ser absorver ou perder humidade, pode ser flexível ou durável, e pode variar em resistência, dureza e cor/textura. Ele também descreve os processos de corte, secagem e distribuição da madeira, bem como suas utilizações na carpintaria, objetos e instrumentos musicais.
O processo de comunicação na pesquisa científica envolve canais informais, como contatos pessoais e discussões em grupos, e canais formais como publicações. Os canais informais permitem troca rápida de ideias entre pares, enquanto os formais tornam os resultados públicos. Um bom pesquisador se comunica eficientemente e possui qualidades como curiosidade, criatividade e integridade intelectual.
Um texto narrativo conta uma história através de três partes principais: introdução, desenvolvimento e conclusão. A introdução apresenta a situação inicial e as personagens. O desenvolvimento descreve os acontecimentos da história. A conclusão mostra o desfecho da trama. Uma narrativa pode ser fechada, com conclusão conhecida, ou aberta, sem desfecho revelado.
Unit 5 - Arranging and Paying for Business Travel & AccommodationRobbieA
The document discusses procedures for arranging and paying for business travel and accommodation. It explains that administrative assistants are responsible for arranging travel based on information from employees' travel request forms. These forms provide important details like travel dates and budgets. The assistant then books travel and accommodation using various sources like the internet, following company policies. Various transportation and accommodation options are considered, balancing factors like cost, convenience and meeting needs.
The document provides an introduction to the C programming language, including its history, features, character sets, tokens, data types, operators, and the basic structure of a C program. It discusses key concepts such as variables, constants, comments, functions, input/output, and how to compile and execute a C program.
The document provides an introduction to the C programming language, including its history, features, character sets, tokens, data types, operators, and the basic structure of a C program. It discusses key concepts such as variables, constants, comments, functions, preprocessing directives, and how to compile and execute a C program.
C Programming - Basics of c -history of cDHIVYAB17
The document provides an introduction to C programming, covering topics such as what a program is, programming languages, the history of C, and the development stages of a C program. It discusses the key components of a C program including directives, the main function, and program structures. Examples are provided to illustrate C code structure and the use of variables, keywords, operators, input/output functions, and formatting output with printf.
And practice program with some MCQ questions to familiar with the concepts.
This document discusses various concepts related to C programming including data types, operators, decision making statements, and loops. It begins with an example "Hello World" C program and explains each part. It then covers various data types in C like integer, float, char, etc. along with their sizes and ranges. Different types of operators like arithmetic, logical, assignment, increment/decrement are described. Decision making statements like if, if-else, if-else ladder, nested if, switch case are explained with examples. Finally, it briefly introduces the three types of loops in C - while, do-while, and for loops.
The document discusses various topics related to tokens, variables, data types, and operators in C programming. It defines tokens as the smallest elements identified by the compiler, such as keywords, identifiers, string literals, and operators. It describes different variable types like local variables, global variables, and static variables. It also explains various data types in C like integer, float, char, etc and their sizes and ranges. Finally, it discusses various arithmetic, relational, logical, and assignment operators in C and their precedence.
The document provides an overview of fundamental programming concepts in C language. It begins by comparing the steps to learning English and C, then discusses algorithms, flowcharts, tokens, data types, operators, control structures like if/else, switch, loops (while, do-while, for). It also covers nested loops, and illustrates an infinite loop that repeats until the user enters 'n'. The key topics covered include basic syntax, flow control, and programming constructs in C.
This PPT is all about INTRODUCTION TO C LANGUAGE in which all basic topics are covered and the information present in this is refered from a book called "Let Us C" by YASHAVANT KANETKAR i.e. This PPT is having all important points of first chapter of "Let Us C". If any doubt plz ask us in comment.
The document provides an overview of the C programming language. It discusses that C is commonly used for embedded systems and systems programming tasks like operating systems and compilers. It was developed between 1969-1973 along with Unix. The "Hello World" example program is shown to demonstrate the basic structure of a C program with main() as the entry point. Data types, variables, and basic I/O functions like printf() and scanf() are described. Operators for arithmetic, comparison, logic, and assignment are also covered.
datypes , operators in c,variables in clanguage formatting input and out putMdAmreen
A data-type in C programming is a set of values and is determined to act on those values.
C provides various types of data-types which allow the programmer to select the appropriate type for the variable to set its value.
The data-type in a programming language is the collection of data with values having fixed meaning as well as characteristics. Some of them are an integer, floating point, character, etc.
Usually, programming languages specify the range values for given data-type.
This document provides an introduction to C++ programming, covering key concepts like characters, tokens, keywords, identifiers, literals, operators, input/output, variables, comments, and common errors. It explains that C++ was created by Bjarne Stroustrup in the 1980s as an extension of C with object-oriented features from Simula 67.
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.
Esoft Metro Campus - Certificate in c / c++ programmingRasan Samarasinghe
Esoft Metro Campus - Certificate in java basics
(Template - Virtusa Corporate)
Contents:
Structure of a program
Variables & Data types
Constants
Operators
Basic Input/output
Control Structures
Functions
Arrays
Character Sequences
Pointers and Dynamic Memory
Unions
Other Data Types
Input/output with files
Searching
Sorting
Introduction to data structures
This page contains examples and source code on decision making in C programming (to choose a particular statement among many statements) and loops ( to perform repeated task ). To understand all the examples on this page, you should have knowledge of following topics:
if...else Statement
for Loop
while Loop
break and Continue Statement
switch...case
Structure Computer Programming with C-02 by Alamgir Hossain
Topics Covered: Introduction of a C program with Proper Exam. From this slide you will learn all about a c program.
The document discusses functions in C programming. It covers:
- Functions allow dividing programs into reusable blocks of code. They can be called multiple times.
- Advantages include avoiding duplicating code, calling functions from anywhere, and improving readability. However, function calls require overhead.
- There are three aspects of a function: declaration, call, and definition. Declaration specifies the name, parameters, and return type. Definition contains the code.
- Functions can return values or not. They can accept arguments or not. Library functions are predefined, while user-defined functions are created by the programmer.
Fundamental of C Programming Language and Basic Input/Output Functionimtiazalijoono
Fundamental of C Programming Language
and
Basic Input/Output Function
contents
C Development Environment
C Program Structure
Basic Data Types
Input/Output function
Common Programming Error
How to use nRF24L01 module with ArduinoCircuitDigest
Learn how to wirelessly transmit sensor data using nRF24L01 and Arduino Uno. A simple project demonstrating real-time communication with DHT11 and OLED display.
☁️ GDG Cloud Munich: Build With AI Workshop - Introduction to Vertex AI! ☁️
Join us for an exciting #BuildWithAi workshop on the 28th of April, 2025 at the Google Office in Munich!
Dive into the world of AI with our "Introduction to Vertex AI" session, presented by Google Cloud expert Randy Gupta.
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.
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
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).
ELectronics Boards & Product Testing_Shiju.pdfShiju Jacob
This presentation provides a high level insight about DFT analysis and test coverage calculation, finalizing test strategy, and types of tests at different levels of the product.
This paper proposes a shoulder inverse kinematics (IK) technique. Shoulder complex is comprised of the sternum, clavicle, ribs, scapula, humerus, and four joints.
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.
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.
Fluid mechanics is the branch of physics concerned with the mechanics of fluids (liquids, gases, and plasmas) and the forces on them. Originally applied to water (hydromechanics), it found applications in a wide range of disciplines, including mechanical, aerospace, civil, chemical, and biomedical engineering, as well as geophysics, oceanography, meteorology, astrophysics, and biology.
It can be divided into fluid statics, the study of various fluids at rest, and fluid dynamics.
Fluid statics, also known as hydrostatics, is the study of fluids at rest, specifically when there's no relative motion between fluid particles. It focuses on the conditions under which fluids are in stable equilibrium and doesn't involve fluid motion.
Fluid kinematics is the branch of fluid mechanics that focuses on describing and analyzing the motion of fluids, such as liquids and gases, without considering the forces that cause the motion. It deals with the geometrical and temporal aspects of fluid flow, including velocity and acceleration. Fluid dynamics, on the other hand, considers the forces acting on the fluid.
Fluid dynamics is the study of the effect of forces on fluid motion. It is a branch of continuum mechanics, a subject which models matter without using the information that it is made out of atoms; that is, it models matter from a macroscopic viewpoint rather than from microscopic.
Fluid mechanics, especially fluid dynamics, is an active field of research, typically mathematically complex. Many problems are partly or wholly unsolved and are best addressed by numerical methods, typically using computers. A modern discipline, called computational fluid dynamics (CFD), is devoted to this approach. Particle image velocimetry, an experimental method for visualizing and analyzing fluid flow, also takes advantage of the highly visual nature of fluid flow.
Fundamentally, every fluid mechanical system is assumed to obey the basic laws :
Conservation of mass
Conservation of energy
Conservation of momentum
The continuum assumption
For example, the assumption that mass is conserved means that for any fixed control volume (for example, a spherical volume)—enclosed by a control surface—the rate of change of the mass contained in that volume is equal to the rate at which mass is passing through the surface from outside to inside, minus the rate at which mass is passing from inside to outside. This can be expressed as an equation in integral form over the control volume.
The continuum assumption is an idealization of continuum mechanics under which fluids can be treated as continuous, even though, on a microscopic scale, they are composed of molecules. Under the continuum assumption, macroscopic (observed/measurable) properties such as density, pressure, temperature, and bulk velocity are taken to be well-defined at "infinitesimal" volume elements—small in comparison to the characteristic length scale of the system, but large in comparison to molecular length scale
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.
2. C Programming Tutorial
Contents:
Introduction
a) History and Usages
b) Keywords
c) Identifiers
d) Variables and Constants
e) Programming Data Types
f) Input and Output
g) Programming Operators
Decision and Loops
a) If…If else and Nested If else
b) C Programming Loops
c) Break and Continue
d) Switch…..case Statement
e) go to function
C Functions
a) User Defined
b) Function Recursion
c) Storage class
Arrays
a) One Dimensional Array
b) Multi dimensional Array
Pointers
a) Pointers and Function
String
Structure and Union
a) Union
Advance Functions in C
a.) Enumeration
b.) Pre-processor
c.) Library Function
3. Chapter 1
Introduction
a.) History
C is a general purpose, structured programming language. It was
developed by Dennis Ritchie in 1970 in BELL Lab.
C Programming is widely used in the Programming world for to
develop all the advanced applications. This tutorial will use you to learn all the
basic things in the C Programming.
Advantages of C:
Flexible
Highly portable
Easily extended by the user
Faster and Efficient
Include number of Built-In-function
Disadvantages of C:
No runtime checking
It is very executable to fixed bugs
Application of C:
Unix completely developed by C
Many desktop application developed by C
Used to solve mathematical functions
It is used to implement different OS.
Getting Started with C:
For clear understanding we have to run all the basic concepts, In order
to run programs we need compiler, compiler will change the source code to
object code and create executable files. For practical uses we install the basic
compiler Turbo C/ Advanced compiler Codelite.
Character Set:
Character set are the set of alphabets, numbers and some special
characters which is valid in C.
4. Alphabets:
Upper Case: A to Z
Lower Case: a to z
Digits:
0 to 9
Special characters:
Here some of the special characters used in C
> < $ ,
# ^ ” “
} { ( )
b.) Keyword:
Keyword is the reserved words used in programming. Each
keyword has fixed meaning and it cannot be changed by any users.
Ex: int money;
Here int is a keyword.
Keyword is a case-sensitive and all keyword must be in lower case.
Keywords in C Language
auto double int struct
break else long switch
case enum register typedef
char extern return union
continue for signed void
do if static while
default goto sizeof volatile
const float short unsigned
5. c.) Identifiers:
Identifiers are name given to C entities such as structures, keywords
or functions etc… Identifiers are unique name given to the C entities which is
used to identify during the execution.
Ex: int money;
Here money is an identifier. Identifier can be in Upper or Lower
case. It can be start with digits or “_”.
d.) Variables and constants:
Variables:
Variables are used to store memory location in system memory,
each variable have unique identifiers.
Ex: int num;
“num” is a variable for integer type.
Variable didn’t contain case sensitive, it may be start with underscore or digits.
Constants:
Constants are the term which cannot be changed during the execution of the
program. It may be classified into following types:
Character Constant:
Character constant are the constant which used in single quotation
around characters. For example: ‘a’, ‘I’, ‘m’, ‘F’.
Floating Point constant:
It may be numerical form that maybe fractional or exponential
form.
Ex: -0.012
1.23 etc…
Integer Constant:
Integers constant are the numeric constants without any floating
point/exponential constant or character constant. It classified into 3 types:
o Octal digits: 0,1,2,3,4,5,6,7
o Decimal Digits: 0,1,2,3,4,5,6,7,8,9
o Hexadecimal digits: 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F,G,H
6. Escape Sequence
Sometimes it is necessary to use newline, tab etc… so we have to use
“/” which is known as Escape sequence.
Escape Sequences
Escape Sequences Character
b Backspace
f Form feed
n Newline
r Return
t Horizontal tab
v Vertical tab
Backslash
' Single quotation mark
" Double quotation mark
? Question mark
0 Null character
String Constant:
Which are enclosed in double quote mark. For example
“good”.
Enumeration Constant:
Keyword enum is used to declare enumeration. For example
enum color{yellow,white,green}
here the variable name is yellow,white,green are the enumeration constant
which having values 0,1,2 respectively.
e.) Programming Data types
Data types in C are classified into 2 types:
1. Fundamental data types
2. Derived Data Types
Syntax for Data types: Data type variable name;
7. Classifications of Fundamental Data types
Integer Type: Keyword int is used for declaring with integer types
Floating Types: Keyword float and double are used for declaring the floating
types
Character Types: keyword char is used for declaring the variables of character
type.
Classifications of Derived Data types
Arrays
Structure
Enumeration
Pointers
Qualifiers: It is used to alter the meaning of base data types to yield a new data
type.
f.) Input/output:
The C Program input and output functions are printf() and scanf()
Printf() it’s used to provide output to the users
Scanf() it’s used to taken input from the users.
Examples for I/O function
#include<stdio.h>
Void main();
{
int c;
printf(“enter the number c”);
scanf(“%d”,&c);
printf(“number=%d,c”);
return 0;
}
Here printf() is used to display the output .
8. Scanf() is ask the value from the user ‘&’ denotes that the address of the C and
value stored in the number.
Stdio represent standard input output function which is the library function
#include is used to paste the code from the header when it is required.
g.) Programming Operators:
Operators are a symbol which operates on a value or variable. For Example:
+ is an operator which is used for a addition.
Operators in C programming
Arithmetic operators(+,-,%,*)
Increment and Decrement operators(a++,++a,a--,--a)
Assignment operators(+=,a+=b is equal to a=a+b)
Relational operators(==,<=,>=)
Logical operators(&&,||)
Conditional operators (?,: it’s used to making decision)
Bitwise operators(&,| etc)
9. Chapter-2
Decision and loops
a.) If, If…else, Nested If…else….
This Statement is used to execute the programming by one
time decision i.e. execute one code and ignore one code.
If Statement
It executes the statement if the test expression is true.
Syntax:
if (test expression)
{
// statement to be executed when the test expression is true
}
If..else Statement
This statement is used when the programmer is want to execute one
statement if the test expression is true or executes other expression if the test
expression is false.
Syntax:
10. if (test expression)
{
Statement to be execute when expression is true;
}
else
{
Statement to be executed when it is false;
}
Nested if else statement
This statement is used when the programmers need more than one
expression.
The nested statement is work by step by step if first statement is true it never
enter t the 2nd
statement when it is wrong it will go to the next expression. This
will used by programmers when they need to check more than one expression.
Syntax:
if(test expression)
{
execute if expression is true; }
11. else if( test expression 1)
{
execute when expression 0 is false and 1 is true;
}
else if (test expression 2)
{
execute when expression 0 and 1 are false and 2 is true);
}
.
.
.
else
{execute the statement when all the above are false;
}
b.) C Programming Loops
Loops are used when the programmer wants to execute the same block
repeatedly for number of times. Loop function executes the certain block of
code until the code becomes false.
Types of Loops:
1. for Loop
2. while Loop
3. do…while Loop
for Loop
for loop execute the program block until the given statement is false.
Syntax:
for(initialization; expression; update statement)
{
Body of the code ;}
12. The Initialization process run only at initial stage of the
programming then it checks the expression if the expression is false loop is
terminated. It is true it executes the code of the body and then executes the
update statement. This process repeats until expression becomes false.
13. Example Program: Find out the sum of n Natural Numbers, when n is
entered by the users.
#include<stdio.h>
#include<conio.h>
int main()
{
int n,c,s=0;
printf("enter the value of n");
scanf("%d",&n);
for(c=1;c<=n;c++)
{
s=s+c;
}
printf("s=%d",s);
getch();
return 0;
}
Output
Enter the value of n=9
S=45
14. While Loop
It checks while expression is true of false. If the expression is true it
executes the body of the loop after the execution it checks the body again this
process continues until it becomes false.
Syntax:
while (test expression)
{
Body of the loop; }
Example: Find the factorial of the number
#include<stdio.h>
int main()
{
int factorial,number;
printf(“enter a number n”)
scanf(“%d”,&number);
factorial=1;
while(number>0)
{ factorial=factorial*number;
--factorial;
}
15. printf( factorial=%d”, factorial);
return 0; }
do…while loop
The only difference between the while and do while is it executes the
statement and then check the test expression.
Syntax:
do
{code to be execute; }
while(test expression);
Write a C program to add the numbers until the user enter the zero
#include<stdio.h>
int main()
{
int num,sum=0;
do
{ printf(“enter a number n”);
scanf(“%d”,&num);
sum=sum+num;
}
while(num!=0);
16. printf (“%d”,sum);
return 0;}
Summary
for loop while loop do..while loop
Initialization,
It is usually counter
variable, statement that
will be executed every
iteration of the loop,
until the counter variable
increment or decrement
It checks the condition
first, if condition is false
it never enter into the
loop.
It executes the
statement before checks
the condition at least one
iteration takes place
when the condition is
false
c.) Break and Continue
The two statements break and continue is used to skip or terminate the
some programming blocks without checking it.
Break statement
It is used to terminate the loop if the statement is true.
Syntax:
break;
Example: write a C program to find the average value of numbers, terminate
the program if the input is negative display the average value and end the
program
#include<stdio.h>
int main()
17. {
int n,i;
float average,num,sum;
printf(“maximum numbers of inputs”);
scanf(“%d”,&n);
for(i=1;i<=n;++i)
{ printf(“enter the n %d”,i);
scanf(“%d”,&n);
if(num<0)
break;
sum=num+sum;}
average=sum/(i-1);
printf(“Average=%.2f”,average);
return 0;
}
Continue Statement
To skip some statement in the function continue statement is used
Syntax;
continue;
18. Example: Write a C program to find the product of 4 numbers
#include<stdio.h>
int main()
{ int i,num,product;
for(i=1,product=1;i<=4;++i)
{ printf(“enter the num %d”,i);
scanf(“%d”,&num);
if(num==0)
continue;
product*=num;}
printf(“product=%d”,product);
return 0; }
Break Continue
It can appear in loop and switch
statements.
It can appear only in loop statement.
It terminates the switch or loop
statement when break is encountered.
It does not cause the termination,
when continue encountered it executes
all iteration in the loops
d.) switch…..case Statement
Decision making are used to select the particular block or code with many
other alternative codes. Instead of switch case we can use nested if else but it is
more complicated while compare with switch case.
Syntax:
switch (n) {
case constant 1:
A code to be executed if n is equal to constant 1;
break;
case constant 2:
19. A code to be executed if n is equal to constant 2;
break;
.
.
.
default:
codes to be executed if n is not equal to any constants;
}
Example Program: Write a program to select the arithmetic operator and two
operands and perform the corresponding operations
#include<stdio.h>
int main()
{
char o;
float n1,n2;
20. printf(“select an operator + or – or * or n);
scanf(“%c”,&o);
printf(“enter the two operands:”);
scanf(“%f%f”,&n1,&n2);
switch(o)
{
case +:
printf(“%.1f+%.1f=%.1f”,num1,num2,num1+num2);
break;
case -:
printf(“%.1f-%.1f=%.1f”,num1,num2,num1-num2);
case *:
printf(“%.1f*%.1f=%.1f”,num1,num2,num1*num2);
case :
printf(“%.1f %.1f=%.1f”,num1,num2,num1num2);
default:
printf(‘operator Error”);
break;
}
return 0; }
e.) go to function
This statement is used to altering the normal sequence of program by
transferring control to some other parts.
Syntax:
goto label;
…………….
…………….
21. label;
statement;
we are not using goto statement because it’s make more complex and
considered as a harmful construct. goto statement is replaced by the use of break
and continue statement.
22. Chapter 3
C Functions
A function is a segment which is used to perform the specified task. A
C program has at least one main() function, without main there is no C
programs.
Types of C Functions
Library Functions
User defined functions
Library Functions
It is a built in function in C programming
Example:
main() --- Every programs start with main function
print() --- used to display the output
scanf() --- used to enter the input
a.) User Defined Function
C allows the programmer to define the function according to their
requirements. For example, a programmer wants to find the factorial and check
whether it is prime number or not in the same program, we can use the 2
functions in the same program.
Working of User defined:
#include<stdio.h>
void function_name()
{……………………
………………………}
int main()
{ ………………………..
………………………….
23. Function name();
……………………
……………………. }
As we mentioned earlier C program is starts with main function when
the program reaches to the function name it jumps to the void function name
after execution of the void function it return to the function name and executes
it.
Advantages:
Easily maintain and debug, large no of codes easily divided in to small
segments and decompose the work load.
Example:
#include<stdio.h>
int add(int a,int b); //Function declaration(prototype)
int main()
{int num1,num2,sum;
printf(“enter the numbers to add”);
scanf(“%d %d”,&num1,num2);
sum=add(num1,num2); //function call
printf(“sum=%d”,sum);
return 0;
}
int add(int a,int b);
{
int add;
add=a+b;
return add;}
24. Function Declaration (prototype)
Every function has to declare before they used, these type of declaration
are also called function prototype. It gives compiler information about name,
function, type of argument that has to pass.
Syntax of Prototype
return-type fun-name ( type(1) argument(1)…………….type(n) argument(n));
From the above example
int add(int a,int b); this is function prototype
fun-name add
return type int
Function call:
Control of the program transferred to the user defined when the function
is called.
Syntax:
function_name(arg 1,arg2);
Function Definition:
It contains specific codes to perform specific task. It is the first line of function
declaration.
Syntax:
function name(arg(1),arg(2))
b.) Function Recursion:
The function that calls itself without any other external functions is known
as recursion.
Example:
#include<stdio.h>
int sum(int n);
int main()
{ int num,add;
25. printf(“enter a positive integer”);
scanf(“%d”,&n);
add=sum(n);
printf(“sum=%d”,add);
}
int sum(int n)
{
if(n==0)
return n;
else
return n+sum(n-1);}
Advantage:
It is more elegant and requires few variables which make program clean
It replaced the complex nesting code function.
Disadvantage:
It is hard to write the recursion.
Hard to debug.
c.) C Programming Storage:
Every variable has two properties:
Type
Storage
Type refers to the function whether it is integer or floating or character
Storage refers how long it stays. It is classifies into 4 types:
Auto
External
Static
Register
26. auto: Variable declared by the inside of the function by default. It access by the
local variables only.
external: It can be accessed by the any function. It is called as global variables
and it declared outside in the function.
static: The value of static variable persists until the end of the program.
register: Register variable are similar like auto and used in global variable.
27. Chapter-4
Arrays
Main use of array is to handle similar type of data’s. For example, if the
company wants to save 100 employees details. By using simple code form, the
programmer has to be creating the data for 100 employees individually, but by
using arrays we can easily replace it.
An Array is a sequence of data types for homogeneous type.
Arrays are two types
1. One Dimensional Array
2. Multi dimensional array
a.)One Dimensional Array:
Declaration of One Dimensional Array:
declaration_type array_name[array_size];
Example: int age[5];
Array Element:
Size of array defines the number of elements used in the array. Each
element can be accessed by the user by their usage.
int age[5];
Age[0] Age[1] Age[2] Age[3] Age[4]
Every array element can be start by 0;
Example:
#include<stdio.h>
void main()
{
int marks[10],i,n,sum=0;
printf(“enter the number of students:”);
scanf(“%d”,&n);
for(i=0;i<n;i++)
28. { printf(“enter the number of students%d:”,i+1);
scanf(“%d”,&marks[i]);
sum=sum+marks[i];}
printf(“sum=%d”,sum);
return 0; }
b.) Multi Dimensional Array:
C Program allows programmers to create array of arrays in the
program.
Ex:
float a[2][6];
Here, an array of two dimensions, this is example of multi-dimensional array.
Initialization of Array:
a[2][4]={{1,2,0,0} ,{3,4,5,6}};
29. Chapter-5
Pointer
Pointers are the important feature it’s different the C and
C++ from java and other languages. Pointers are used to access the memory and
manipulate the address.
Reference Operator (&):
& denotes address in the memory
Lets explain in the program
#include<stdio.h>
int main()
{ int var=5;
printf(“value=%d”,var);
printf(“address=%d”,&var);
return 0;}
Output:
Value=5
Address=2567891
From the above code we can know clearly var is a name given to that location
and 5 is stored in the 2567891 location.
Reference Variable (*):
It is used to hold the memory address i.e is variable that holds address is
Reference variable
Arrays Pointers
Array is a single, pre-allocated and
continues element
Pointer is a place in a memory which is
used to store the another place or
function
It can’t be resized It can be resized
30. It can be initialized It can’t be initialized
a.) Pointers and Functions
When the Argument is passed using pointer address of the memory
location is passed instead of value.
Example:
#include<stdio.h>
void swap(int *a,int *b);
int main()
{ int n1=5,n2-10;
swap(&n1,&n2);
printf(“n1=%d n”,n1);
printf(“n2=%d’,n2);
return 0; }
void swap(int *a, int *b)
{ int temp;
temp=*n1;
*n1=*n2; *n2=temp; }
The address of n1 and n2 are passed to the memory location of pointer a and b,
So the value of the memory location changed the value in memory location also
changed, clearly if the *a and *b are changed it will reflected in n1 & n2
This is known as call by reference.
31. Chapter-6
String
Array of character is string.
Declaration of String:
String is declared like array the difference is string is denoted as char only
char S[5];
S[0] S[1] S[2] S[3] S[4]
Declaration by using pointer
char *p;
Initialization of string:
char c[]="abcd";
char[5]= "abcd";
char[]={‘a’, ‘b’,‘c’,‘d’,‘0’};
Example: How to read string from terminal
#include<stdio.h>
#include<string.h>
int main()
{char name[20];
printf(“enter name:”);
scanf(“%s”,name);
printf(“your name is %s:”,name);
return 0;}
output:
Enter name: Swan Tech
Your name is: Swan
32. Here the compiler will give the first name only because there is white
space
String Handling Functions
We can use strings for various application like finding length etc.. but
programmer can use the library function string.h in the program
We can manipulate the string function manually so we use the handling
functions.
Function Explanation
strlen() Length of the string
strcpy() Copy the string
strcat() Joins two string
strcmp() Compare two strings
gets() and puts()
we can use this gets and puts condition to take input string and display
the output string
Example:
#include<stdio.h>
#include<string.h>
int main()
{ char name[30];
printf(“enter the name”);
gets(name);
printf(“The name enter is:”);
puts(name);
return 0;}
Here gets and puts are likely scanf() and printf()
33. Chapter-7
Structure and Union
Structure:
Structure is the collection variable that is used to store the different variables
under a single name. If you want to store the different details of the students like
register number, marks, details etc
We are using structure for the better approach.
Definition:
Keyword struct is used for denote the function.
Syntax:
struct_structure name
{ datatype 1;
datatype 2;
.
.
datatype n;}
Union
Union is similar to the structure, it derived from the structure and we sued union
keyword to denote it in the code
The main difference is All members can be accessed the structure but only the
members in the union can access the code
34. Structure Union
Using keyword struct for denote Using keyword union for denote
One or more members can initialize
the function
Only one member can initialize
It allocates memory equal to the sum
of the memory allocated to its each
individual members
It allocates one block memory which is
enough to stored all the data
Each member have their own space Only one memory for all users
35. Chapter-8
Advance Function in c
a.) Enumeration
Enumeration is user defined data type consist of integral constant
and each integral constant have a keyword enum to defined the enumeration
type.
enum type_name{ value 1,value 2…….value n};
By default value 1=1 and value 2=1 but the user can changed the default values.
Example of Enumerated:
#include<stdio.h>
enum week{Sunday,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday};
int main()
{ enum week today;
Today=Wednesday;
printf=(“%d day”,total+1);
return 0;}
Output:
Today=4
b.) Pre-processor
In C language the line which is beginning with # symbol is
known as Pre-processor. It is substitution tool and it instruct compiler to do the
specific function before the compilation of the program.
Example:
#include To insert particular header
#define Substitute a particular macro
36. c.) Library Function
It is inbuilt function of C programming which is written with their
respective header files.
For Example: if you want to run printf() you need to include stdio.h in the
header file.