SlideShare a Scribd company logo
1 of 23
Agenda
 Warm up on line Quiz 1 15 min
 Presentation about types of errors ppt 10 min
 the sequence of program word file 5 min
 Using computers and writing a program using code blocks and the lap tops 35
min
 Exit ticket 5 min
http://www.stemassiut.info prepared by Mr.Osama Ghandour
Visual game
Simple Data Types 2
Now set in groups
During the next PPT
Take note as
groups and I’ll
pick one
answer from
each group
One in desktop presents
One takes picture
One is observer
COS I will take his
comments in the
end of the session
Simple Data Types
4
Data types in C
Only really four basic types:
 char
 int (short, long, long long, unsigned)
 float
 double
Size of these types on
CLEAR machines:
Sizes of these types
vary from one machine
to another!
Type Size
(bytes)
Precision
char 1
int 2 to 4
short 2
long 4
float 4 6 decimal
places
double 8 15 decimal
places
Long double 10 19 decimal
places
Types of Errors
Quiz about data types 10 min
http://www.stemassiut.info prepared by Mr.Osama Ghandour
Warming Up
Types of Errors
 There are three types of errors that may occur while developing or writing C
program. There errors are:
 Syntax Errors
 Logical Errors
 Runtime Errors
http://www.stemassiut.info prepared by Mr.Osama Ghandour
Syntax Errors
 The set of rules (grammatical rules) of a programming language for writing statements of the
computer program is known as syntax of the language. The program statements are written strictly
according to these rules.
Syntax error occur when syntax of a programming language are not followed in writing
the source code. The compiler detects these errors at compiling time of source code. The compiler
reports a proper error message about the error.
The compiler does not compile a program that contain syntax errors. The syntax errors
are easy to detect and remove.
In C program, there can be many causes of syntax errors. Some examples are given below:-
 Missing semicolon ( ; ) at the end of statement.
 Missing any of delimiters i.e { or }
 Incorrect spelling of any keyword.
 Using variable without declaration etc.

http://www.stemassiut.info prepared by Mr.Osama Ghandour
http://www.stemassiut.info prepared by Mr.Osama Ghandour
Syntax Errors
Logical Errors:-
 The errors in the logic of the program are called logical error. The compiler cannot detect logical
errors. A program with logical errors is compiled (translated) and run successfully but it does not give
correct result.

 The sequence of instructions used in a program may be incorrect.
 The mathematical formulas used in program instructions may be incorrect etc.
 The logical errors are difficult to detect. Logical errors can only be detected by examining all the
units of the program one by one. It is a very time consuming and lengthy process.
http://www.stemassiut.info prepared by Mr.Osama Ghandour
Runtime Errors
The errors that occur during the execution of program are called the runtime
errors. These types of errors may occur due to the following reasons.
When the program attempts to perform an illegal operation such as dividing a
number by zero.
If input data given to the program is not in a correct format or input data file
is not found in the specified path.
If hardware problem occurs such as hard disk error, or disk full or
printer error etc.
When a runtime error occurs, the computer stops the execution of program
and displays an error message.
http://www.stemassiut.info prepared by Mr.Osama Ghandour
http://www.stemassiut.info
You studied today about the
types of programming errors
write about how to use this L.O.
learning out come in your
capstone of recycling wasted
energy ?
Brain storm activity
Fred Kuhns
(3/25/2019)
CSE332– Object Oriented Programming Lab
A Simple C Program
 Create example file: try.c
 Compile using gcc:
gcc –o try try.c
 The standard C library libc is included
automatically
 Execute program
./try
 Note, I always specify an absolute path
/* include stdio.h and stdlib.h */
#include <stdio.h>
#include <stdlib.h>
int main (void)
{
printf(“Hello Worldn”);
return 0;
}
Fred Kuhns
(3/25/2019)
CSE332– Object Oriented Programming Lab
Another Simple C Program
int main (int argc, char **argv) {
int i;
printf(“There are %d argumentsn”, argc);
for (i = 0; i < argc; i++)
printf(“Arg %d = %sn”, i, argv[i]);
return 0;
}
•Notice that the syntax is similar to Java
•What’s new in the above simple program?
–of course you will have to learn the new interfaces and utility
functions defined by the C standard and UNIX
Open Code Blocks then
Select the compiler GNU GCC compiler
Then name your project and save it a
folder in a drive .
A default simple code
you will find then write
your code and develop
your program from your
flowchart and defined
issue , build and run
program at first time
from build menu or F9
next time run it by
“CTRL+ F10” , save your
program /project Press here
for on line
Press here
for off line
OR
Home work1 write a program in C Language to
calculate Efficiency of a system / process build
and run the program and test the program to
avoid any error using Code Blocks .
Home work2 write a program in C Language to
calculate the measure of each interior angle of
a regular polygon of n-sides avoid any error
using Code Blocks .
Note the sum of measures of the interior angles
of a polygon of n-sides=(n-2)*180
Home work3 write a program in C Language to
draw a regular polygon of n-sides
5 min Reflection
• Mansion the types of
programming errors write
about how to test the program
to avoid one of them?
Osama Ghandour Geris Assiut STEM
School 21
Thank you
Mr. Osama Ghandour
Types of errors 2019

More Related Content

What's hot

While , For , Do-While Loop
While , For , Do-While LoopWhile , For , Do-While Loop
While , For , Do-While LoopAbhishek Choksi
 
History of asynchronous in .NET
History of asynchronous in .NETHistory of asynchronous in .NET
History of asynchronous in .NETMarcin Tyborowski
 
Fundamental of C Programming Language and Basic Input/Output Function
  Fundamental of C Programming Language and Basic Input/Output Function  Fundamental of C Programming Language and Basic Input/Output Function
Fundamental of C Programming Language and Basic Input/Output Functionimtiazalijoono
 
Design & Analysis of Algorithms Lecture Notes
Design & Analysis of Algorithms Lecture NotesDesign & Analysis of Algorithms Lecture Notes
Design & Analysis of Algorithms Lecture NotesFellowBuddy.com
 
Reduction & Handle Pruning
Reduction & Handle PruningReduction & Handle Pruning
Reduction & Handle PruningMdAshikJiddney
 
Programming languages
Programming languagesProgramming languages
Programming languagesSimon Mui
 
Loops in C Programming Language
Loops in C Programming LanguageLoops in C Programming Language
Loops in C Programming LanguageMahantesh Devoor
 
Error Detection & Recovery
Error Detection & RecoveryError Detection & Recovery
Error Detection & RecoveryAkhil Kaushik
 
Sequences and summations
Sequences and summationsSequences and summations
Sequences and summationsAli Saleem
 
SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...
SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...
SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...vtunotesbysree
 
Decision properties of reular languages
Decision properties of reular languagesDecision properties of reular languages
Decision properties of reular languagesSOMNATHMORE2
 
Compiler design syntax analysis
Compiler design syntax analysisCompiler design syntax analysis
Compiler design syntax analysisRicha Sharma
 
Data members and member functions
Data members and member functionsData members and member functions
Data members and member functionsHarsh Patel
 

What's hot (20)

System calls
System callsSystem calls
System calls
 
Recursion
RecursionRecursion
Recursion
 
While , For , Do-While Loop
While , For , Do-While LoopWhile , For , Do-While Loop
While , For , Do-While Loop
 
Context free grammar
Context free grammar Context free grammar
Context free grammar
 
History of asynchronous in .NET
History of asynchronous in .NETHistory of asynchronous in .NET
History of asynchronous in .NET
 
Fundamental of C Programming Language and Basic Input/Output Function
  Fundamental of C Programming Language and Basic Input/Output Function  Fundamental of C Programming Language and Basic Input/Output Function
Fundamental of C Programming Language and Basic Input/Output Function
 
Syntax analysis
Syntax analysisSyntax analysis
Syntax analysis
 
Design & Analysis of Algorithms Lecture Notes
Design & Analysis of Algorithms Lecture NotesDesign & Analysis of Algorithms Lecture Notes
Design & Analysis of Algorithms Lecture Notes
 
Reduction & Handle Pruning
Reduction & Handle PruningReduction & Handle Pruning
Reduction & Handle Pruning
 
Programming languages
Programming languagesProgramming languages
Programming languages
 
Loops in C Programming Language
Loops in C Programming LanguageLoops in C Programming Language
Loops in C Programming Language
 
Debugging
DebuggingDebugging
Debugging
 
Type Checking(Compiler Design) #ShareThisIfYouLike
Type Checking(Compiler Design) #ShareThisIfYouLikeType Checking(Compiler Design) #ShareThisIfYouLike
Type Checking(Compiler Design) #ShareThisIfYouLike
 
Kleene's theorem
Kleene's theoremKleene's theorem
Kleene's theorem
 
Error Detection & Recovery
Error Detection & RecoveryError Detection & Recovery
Error Detection & Recovery
 
Sequences and summations
Sequences and summationsSequences and summations
Sequences and summations
 
SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...
SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...
SOLUTION MANUAL OF OPERATING SYSTEM CONCEPTS BY ABRAHAM SILBERSCHATZ, PETER B...
 
Decision properties of reular languages
Decision properties of reular languagesDecision properties of reular languages
Decision properties of reular languages
 
Compiler design syntax analysis
Compiler design syntax analysisCompiler design syntax analysis
Compiler design syntax analysis
 
Data members and member functions
Data members and member functionsData members and member functions
Data members and member functions
 

Similar to Types of errors 2019

C and its errors
C and its errorsC and its errors
C and its errorsJunaid Raja
 
(D 15 180770107240)
(D 15 180770107240)(D 15 180770107240)
(D 15 180770107240)RaviModi37
 
Software programming and development
Software programming and developmentSoftware programming and development
Software programming and developmentAli Raza
 
C language industrial training report
C language industrial training reportC language industrial training report
C language industrial training reportRaushan Pandey
 
Learn C Programming Full Course Free
Learn C Programming Full Course FreeLearn C Programming Full Course Free
Learn C Programming Full Course FreeDheeraj Patidar
 
Computer programing 111 lecture 2
Computer programing 111 lecture 2Computer programing 111 lecture 2
Computer programing 111 lecture 2ITNet
 
Fundamentals of programming with C++
Fundamentals of programming with C++Fundamentals of programming with C++
Fundamentals of programming with C++Seble Nigussie
 
Introduction to Computer Programming
Introduction to Computer ProgrammingIntroduction to Computer Programming
Introduction to Computer ProgrammingProf. Erwin Globio
 
1.Overview of Programming.pptx
1.Overview of Programming.pptx1.Overview of Programming.pptx
1.Overview of Programming.pptxVishwas459764
 
Unit 1 program development cycle
Unit 1 program development cycleUnit 1 program development cycle
Unit 1 program development cycleDhana malar
 
Creating a compiler for your own language
Creating a compiler for your own languageCreating a compiler for your own language
Creating a compiler for your own languageAndrea Tino
 
What is turbo c and how it works
What is turbo c and how it worksWhat is turbo c and how it works
What is turbo c and how it worksMark John Lado, MIT
 
How to work with code blocks
How to work with code blocksHow to work with code blocks
How to work with code blocksTech Bikram
 
COM1407: Introduction to C Programming
COM1407: Introduction to C Programming COM1407: Introduction to C Programming
COM1407: Introduction to C Programming Hemantha Kulathilake
 

Similar to Types of errors 2019 (20)

C and its errors
C and its errorsC and its errors
C and its errors
 
(D 15 180770107240)
(D 15 180770107240)(D 15 180770107240)
(D 15 180770107240)
 
Software programming and development
Software programming and developmentSoftware programming and development
Software programming and development
 
C language industrial training report
C language industrial training reportC language industrial training report
C language industrial training report
 
The basics of c programming
The basics of c programmingThe basics of c programming
The basics of c programming
 
Learn C Programming Full Course Free
Learn C Programming Full Course FreeLearn C Programming Full Course Free
Learn C Programming Full Course Free
 
Slide 01
Slide 01Slide 01
Slide 01
 
Computer programing 111 lecture 2
Computer programing 111 lecture 2Computer programing 111 lecture 2
Computer programing 111 lecture 2
 
Cp 111 lecture 2
Cp 111 lecture 2Cp 111 lecture 2
Cp 111 lecture 2
 
Fundamentals of programming with C++
Fundamentals of programming with C++Fundamentals of programming with C++
Fundamentals of programming with C++
 
Introduction to Computer Programming
Introduction to Computer ProgrammingIntroduction to Computer Programming
Introduction to Computer Programming
 
1.Overview of Programming.pptx
1.Overview of Programming.pptx1.Overview of Programming.pptx
1.Overview of Programming.pptx
 
Unit 1 program development cycle
Unit 1 program development cycleUnit 1 program development cycle
Unit 1 program development cycle
 
Introduction to programming c
Introduction to programming cIntroduction to programming c
Introduction to programming c
 
grade 10 2023.pptx
grade 10 2023.pptxgrade 10 2023.pptx
grade 10 2023.pptx
 
Creating a compiler for your own language
Creating a compiler for your own languageCreating a compiler for your own language
Creating a compiler for your own language
 
CS3251-_PIC
CS3251-_PICCS3251-_PIC
CS3251-_PIC
 
What is turbo c and how it works
What is turbo c and how it worksWhat is turbo c and how it works
What is turbo c and how it works
 
How to work with code blocks
How to work with code blocksHow to work with code blocks
How to work with code blocks
 
COM1407: Introduction to C Programming
COM1407: Introduction to C Programming COM1407: Introduction to C Programming
COM1407: Introduction to C Programming
 

More from Osama Ghandour Geris

functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...
functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...
functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...Osama Ghandour Geris
 
Python week 5 2019-2020 for G10 by Eng.Osama Ghandour.ppt
Python week 5 2019-2020 for G10 by Eng.Osama Ghandour.pptPython week 5 2019-2020 for G10 by Eng.Osama Ghandour.ppt
Python week 5 2019-2020 for G10 by Eng.Osama Ghandour.pptOsama Ghandour Geris
 
Python cs.1.12 week 10 2020 2021 covid 19 for g10 by eng.osama mansour
Python cs.1.12 week 10  2020 2021 covid 19 for g10 by eng.osama mansourPython cs.1.12 week 10  2020 2021 covid 19 for g10 by eng.osama mansour
Python cs.1.12 week 10 2020 2021 covid 19 for g10 by eng.osama mansourOsama Ghandour Geris
 
Python cs.1.12 week 9 10 2020-2021 covid 19 for g10 by eng.osama ghandour
Python cs.1.12 week 9 10  2020-2021 covid 19 for g10 by eng.osama ghandourPython cs.1.12 week 9 10  2020-2021 covid 19 for g10 by eng.osama ghandour
Python cs.1.12 week 9 10 2020-2021 covid 19 for g10 by eng.osama ghandourOsama Ghandour Geris
 
Python week 7 8 2019-2020 for grade 10
Python week 7 8 2019-2020 for grade 10Python week 7 8 2019-2020 for grade 10
Python week 7 8 2019-2020 for grade 10Osama Ghandour Geris
 
Python week 6 2019 2020 for grade 10
Python week 6 2019 2020 for grade 10 Python week 6 2019 2020 for grade 10
Python week 6 2019 2020 for grade 10 Osama Ghandour Geris
 
Python week 5 2019 2020 for g10 by eng.osama ghandour
Python week 5 2019 2020 for g10 by eng.osama ghandourPython week 5 2019 2020 for g10 by eng.osama ghandour
Python week 5 2019 2020 for g10 by eng.osama ghandourOsama Ghandour Geris
 
Python week 4 2019 2020 for g10 by eng.osama ghandour
Python week 4 2019 2020 for g10 by eng.osama ghandourPython week 4 2019 2020 for g10 by eng.osama ghandour
Python week 4 2019 2020 for g10 by eng.osama ghandourOsama Ghandour Geris
 
Programming intro variables constants - arithmetic and assignment operators
Programming intro variables   constants - arithmetic and assignment operatorsProgramming intro variables   constants - arithmetic and assignment operators
Programming intro variables constants - arithmetic and assignment operatorsOsama Ghandour Geris
 
Mobile appliaction w android week 1 by osama
Mobile appliaction w android week 1 by osamaMobile appliaction w android week 1 by osama
Mobile appliaction w android week 1 by osamaOsama Ghandour Geris
 
Css week11 2020 2021 for g10 by eng.osama ghandour
Css week11 2020 2021 for g10 by eng.osama ghandourCss week11 2020 2021 for g10 by eng.osama ghandour
Css week11 2020 2021 for g10 by eng.osama ghandourOsama Ghandour Geris
 
How to print a sketch up drawing in 3d
How to print a sketch up drawing  in 3dHow to print a sketch up drawing  in 3d
How to print a sketch up drawing in 3dOsama Ghandour Geris
 
7 types of presentation styles on line
7 types of presentation styles on line7 types of presentation styles on line
7 types of presentation styles on lineOsama Ghandour Geris
 
Design pseudo codeweek 6 2019 -2020
Design pseudo codeweek 6 2019 -2020Design pseudo codeweek 6 2019 -2020
Design pseudo codeweek 6 2019 -2020Osama Ghandour Geris
 

More from Osama Ghandour Geris (20)

functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...
functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...
functions in python By Eng. Osama Ghandour الدوال فى البايثون مع مهندس اسامه ...
 
Python week 5 2019-2020 for G10 by Eng.Osama Ghandour.ppt
Python week 5 2019-2020 for G10 by Eng.Osama Ghandour.pptPython week 5 2019-2020 for G10 by Eng.Osama Ghandour.ppt
Python week 5 2019-2020 for G10 by Eng.Osama Ghandour.ppt
 
Python cs.1.12 week 10 2020 2021 covid 19 for g10 by eng.osama mansour
Python cs.1.12 week 10  2020 2021 covid 19 for g10 by eng.osama mansourPython cs.1.12 week 10  2020 2021 covid 19 for g10 by eng.osama mansour
Python cs.1.12 week 10 2020 2021 covid 19 for g10 by eng.osama mansour
 
Python cs.1.12 week 9 10 2020-2021 covid 19 for g10 by eng.osama ghandour
Python cs.1.12 week 9 10  2020-2021 covid 19 for g10 by eng.osama ghandourPython cs.1.12 week 9 10  2020-2021 covid 19 for g10 by eng.osama ghandour
Python cs.1.12 week 9 10 2020-2021 covid 19 for g10 by eng.osama ghandour
 
Python week 7 8 2019-2020 for grade 10
Python week 7 8 2019-2020 for grade 10Python week 7 8 2019-2020 for grade 10
Python week 7 8 2019-2020 for grade 10
 
Python week 6 2019 2020 for grade 10
Python week 6 2019 2020 for grade 10 Python week 6 2019 2020 for grade 10
Python week 6 2019 2020 for grade 10
 
Python week 5 2019 2020 for g10 by eng.osama ghandour
Python week 5 2019 2020 for g10 by eng.osama ghandourPython week 5 2019 2020 for g10 by eng.osama ghandour
Python week 5 2019 2020 for g10 by eng.osama ghandour
 
Python week 4 2019 2020 for g10 by eng.osama ghandour
Python week 4 2019 2020 for g10 by eng.osama ghandourPython week 4 2019 2020 for g10 by eng.osama ghandour
Python week 4 2019 2020 for g10 by eng.osama ghandour
 
Programming intro variables constants - arithmetic and assignment operators
Programming intro variables   constants - arithmetic and assignment operatorsProgramming intro variables   constants - arithmetic and assignment operators
Programming intro variables constants - arithmetic and assignment operators
 
Mobile appliaction w android week 1 by osama
Mobile appliaction w android week 1 by osamaMobile appliaction w android week 1 by osama
Mobile appliaction w android week 1 by osama
 
Python week 1 2020-2021
Python week 1 2020-2021Python week 1 2020-2021
Python week 1 2020-2021
 
6 css week12 2020 2021 for g10
6 css week12 2020 2021 for g106 css week12 2020 2021 for g10
6 css week12 2020 2021 for g10
 
Css week11 2020 2021 for g10 by eng.osama ghandour
Css week11 2020 2021 for g10 by eng.osama ghandourCss week11 2020 2021 for g10 by eng.osama ghandour
Css week11 2020 2021 for g10 by eng.osama ghandour
 
Cooding history
Cooding history Cooding history
Cooding history
 
Computer networks--network
Computer networks--networkComputer networks--network
Computer networks--network
 
How to print a sketch up drawing in 3d
How to print a sketch up drawing  in 3dHow to print a sketch up drawing  in 3d
How to print a sketch up drawing in 3d
 
Google sketch up-tutorial
Google sketch up-tutorialGoogle sketch up-tutorial
Google sketch up-tutorial
 
7 types of presentation styles on line
7 types of presentation styles on line7 types of presentation styles on line
7 types of presentation styles on line
 
Design pseudo codeweek 6 2019 -2020
Design pseudo codeweek 6 2019 -2020Design pseudo codeweek 6 2019 -2020
Design pseudo codeweek 6 2019 -2020
 
Php introduction
Php introductionPhp introduction
Php introduction
 

Recently uploaded

Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxDeepakSakkari2
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfAsst.prof M.Gokilavani
 
main PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidmain PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidNikhilNagaraju
 
Application of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptxApplication of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptx959SahilShah
 
What are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptxWhat are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptxwendy cai
 
Correctly Loading Incremental Data at Scale
Correctly Loading Incremental Data at ScaleCorrectly Loading Incremental Data at Scale
Correctly Loading Incremental Data at ScaleAlluxio, Inc.
 
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionSachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionDr.Costas Sachpazis
 
Software and Systems Engineering Standards: Verification and Validation of Sy...
Software and Systems Engineering Standards: Verification and Validation of Sy...Software and Systems Engineering Standards: Verification and Validation of Sy...
Software and Systems Engineering Standards: Verification and Validation of Sy...VICTOR MAESTRE RAMIREZ
 
IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024Mark Billinghurst
 
Electronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfElectronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfme23b1001
 
Architect Hassan Khalil Portfolio for 2024
Architect Hassan Khalil Portfolio for 2024Architect Hassan Khalil Portfolio for 2024
Architect Hassan Khalil Portfolio for 2024hassan khalil
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxbritheesh05
 
8251 universal synchronous asynchronous receiver transmitter
8251 universal synchronous asynchronous receiver transmitter8251 universal synchronous asynchronous receiver transmitter
8251 universal synchronous asynchronous receiver transmitterShivangiSharma879191
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvLewisJB
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxKartikeyaDwivedi3
 
Heart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxHeart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxPoojaBan
 
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)dollysharma2066
 

Recently uploaded (20)

Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptx
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
 
main PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidmain PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfid
 
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptxExploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
 
Application of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptxApplication of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptx
 
What are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptxWhat are the advantages and disadvantages of membrane structures.pptx
What are the advantages and disadvantages of membrane structures.pptx
 
Correctly Loading Incremental Data at Scale
Correctly Loading Incremental Data at ScaleCorrectly Loading Incremental Data at Scale
Correctly Loading Incremental Data at Scale
 
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionSachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
 
Software and Systems Engineering Standards: Verification and Validation of Sy...
Software and Systems Engineering Standards: Verification and Validation of Sy...Software and Systems Engineering Standards: Verification and Validation of Sy...
Software and Systems Engineering Standards: Verification and Validation of Sy...
 
IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024
 
Electronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdfElectronically Controlled suspensions system .pdf
Electronically Controlled suspensions system .pdf
 
POWER SYSTEMS-1 Complete notes examples
POWER SYSTEMS-1 Complete notes  examplesPOWER SYSTEMS-1 Complete notes  examples
POWER SYSTEMS-1 Complete notes examples
 
Architect Hassan Khalil Portfolio for 2024
Architect Hassan Khalil Portfolio for 2024Architect Hassan Khalil Portfolio for 2024
Architect Hassan Khalil Portfolio for 2024
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptx
 
8251 universal synchronous asynchronous receiver transmitter
8251 universal synchronous asynchronous receiver transmitter8251 universal synchronous asynchronous receiver transmitter
8251 universal synchronous asynchronous receiver transmitter
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvv
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptx
 
Heart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxHeart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptx
 
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Serviceyoung call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
 
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
 

Types of errors 2019

  • 1. Agenda  Warm up on line Quiz 1 15 min  Presentation about types of errors ppt 10 min  the sequence of program word file 5 min  Using computers and writing a program using code blocks and the lap tops 35 min  Exit ticket 5 min http://www.stemassiut.info prepared by Mr.Osama Ghandour
  • 3. Now set in groups During the next PPT Take note as groups and I’ll pick one answer from each group One in desktop presents One takes picture One is observer COS I will take his comments in the end of the session
  • 4. Simple Data Types 4 Data types in C Only really four basic types:  char  int (short, long, long long, unsigned)  float  double Size of these types on CLEAR machines: Sizes of these types vary from one machine to another! Type Size (bytes) Precision char 1 int 2 to 4 short 2 long 4 float 4 6 decimal places double 8 15 decimal places Long double 10 19 decimal places
  • 5. Types of Errors Quiz about data types 10 min http://www.stemassiut.info prepared by Mr.Osama Ghandour Warming Up
  • 6. Types of Errors  There are three types of errors that may occur while developing or writing C program. There errors are:  Syntax Errors  Logical Errors  Runtime Errors http://www.stemassiut.info prepared by Mr.Osama Ghandour
  • 7. Syntax Errors  The set of rules (grammatical rules) of a programming language for writing statements of the computer program is known as syntax of the language. The program statements are written strictly according to these rules. Syntax error occur when syntax of a programming language are not followed in writing the source code. The compiler detects these errors at compiling time of source code. The compiler reports a proper error message about the error. The compiler does not compile a program that contain syntax errors. The syntax errors are easy to detect and remove. In C program, there can be many causes of syntax errors. Some examples are given below:-  Missing semicolon ( ; ) at the end of statement.  Missing any of delimiters i.e { or }  Incorrect spelling of any keyword.  Using variable without declaration etc.  http://www.stemassiut.info prepared by Mr.Osama Ghandour
  • 8. http://www.stemassiut.info prepared by Mr.Osama Ghandour Syntax Errors
  • 9. Logical Errors:-  The errors in the logic of the program are called logical error. The compiler cannot detect logical errors. A program with logical errors is compiled (translated) and run successfully but it does not give correct result.   The sequence of instructions used in a program may be incorrect.  The mathematical formulas used in program instructions may be incorrect etc.  The logical errors are difficult to detect. Logical errors can only be detected by examining all the units of the program one by one. It is a very time consuming and lengthy process. http://www.stemassiut.info prepared by Mr.Osama Ghandour
  • 10. Runtime Errors The errors that occur during the execution of program are called the runtime errors. These types of errors may occur due to the following reasons. When the program attempts to perform an illegal operation such as dividing a number by zero. If input data given to the program is not in a correct format or input data file is not found in the specified path. If hardware problem occurs such as hard disk error, or disk full or printer error etc. When a runtime error occurs, the computer stops the execution of program and displays an error message. http://www.stemassiut.info prepared by Mr.Osama Ghandour
  • 12. You studied today about the types of programming errors write about how to use this L.O. learning out come in your capstone of recycling wasted energy ? Brain storm activity
  • 13. Fred Kuhns (3/25/2019) CSE332– Object Oriented Programming Lab A Simple C Program  Create example file: try.c  Compile using gcc: gcc –o try try.c  The standard C library libc is included automatically  Execute program ./try  Note, I always specify an absolute path /* include stdio.h and stdlib.h */ #include <stdio.h> #include <stdlib.h> int main (void) { printf(“Hello Worldn”); return 0; }
  • 14. Fred Kuhns (3/25/2019) CSE332– Object Oriented Programming Lab Another Simple C Program int main (int argc, char **argv) { int i; printf(“There are %d argumentsn”, argc); for (i = 0; i < argc; i++) printf(“Arg %d = %sn”, i, argv[i]); return 0; } •Notice that the syntax is similar to Java •What’s new in the above simple program? –of course you will have to learn the new interfaces and utility functions defined by the C standard and UNIX
  • 16. Select the compiler GNU GCC compiler
  • 17. Then name your project and save it a folder in a drive .
  • 18. A default simple code you will find then write your code and develop your program from your flowchart and defined issue , build and run program at first time from build menu or F9 next time run it by “CTRL+ F10” , save your program /project Press here for on line Press here for off line OR
  • 19. Home work1 write a program in C Language to calculate Efficiency of a system / process build and run the program and test the program to avoid any error using Code Blocks .
  • 20. Home work2 write a program in C Language to calculate the measure of each interior angle of a regular polygon of n-sides avoid any error using Code Blocks . Note the sum of measures of the interior angles of a polygon of n-sides=(n-2)*180 Home work3 write a program in C Language to draw a regular polygon of n-sides
  • 21. 5 min Reflection • Mansion the types of programming errors write about how to test the program to avoid one of them? Osama Ghandour Geris Assiut STEM School 21