Introduction to turbo c

seCreTlyiNvoLvE 256 views 14 slides Jan 30, 2012
Slide 1
Slide 1 of 14
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14

About This Presentation

For computer LT 4th quarter


Slide Content

Powerpoint Templates
ARVIN
santos
buendia

Powerpoint Templates
OBJECTIVES

Powerpoint Templates
INTRODUCTION TO TURBO-C

Powerpoint Templates
INTRODUCTION TO TURBO-C

Powerpoint Templates
TURBO-C CODE STRUCTURE
COMMENTS
PREPROCESSOR DIRECTIVE
BEGIN BLOCK OF main( ) FUNCTION
END BLOCK OF main( ) FUNCTION
VARIABLE DECLARATION
FUNCTION NAME
BODY OF THE
PROGRAM
Hello Arvin_ _Hello SUPERMAN_

Powerpoint Templates
SCREEN OUTPUT FUNCTION
printf( ); – is used to write information
on the screen
printf(<format string>);
<format string> is a string that begins
and ends with double quotes “”
printf(“ARVIN santos BUENDIA”);
ARVIN santos BUENDIA_ _

Powerpoint Templates
SCREEN OUTPUT FUNCTION
An ESCAPE SEQUENCE that starts with
the escape code “\”
The backslash indicates that the
characters that will follow is NOT TO BE
PROCESS in the ORDINARY WAY
 
ESCAPE SEQUENCE
\n new line
\t tab
\” double quote
\\ backslash

Powerpoint Templates
SCREEN OUTPUT FUNCTION
printf(“arvin \nSUPERMAN”);
arvin_ _
_SUPERMAN_

Powerpoint Templates
SCREEN OUTPUT FUNCTION
printf(“arvin \n SUPERMAN”);
arvin_ _
_SUPERMAN__

Powerpoint Templates
SCREEN OUTPUT FUNCTION
printf(“arvin \tSUPERMAN”);
arvin_ _SUPERMAN__

Powerpoint Templates
SCREEN OUTPUT FUNCTION
printf(“arvin “ SUPERMAN”);
arvin_ _
START OF THE FORMAT STRING END OF THE FORMAT STRING
SYNTAX ERROR NEXT CODE

Powerpoint Templates
ESCAPE SEQUENCE
START OF THE FORMAT STRING
SCREEN OUTPUT FUNCTION
printf(“arvin \" SUPERMAN”);
arvin_ _“SUPERMAN_
END OF THE FORMAT STRING
NEXT CODE

Powerpoint Templates
ESCAPE SEQUENCE
START OF THE FORMAT STRING
SCREEN OUTPUT FUNCTION
printf(“arvin \\SUPERMAN”);
arvin_ _\SUPERMAN_
END OF THE FORMAT STRING
NEXT CODE

Powerpoint Templates
ASSESSMENT
printf(“\\di nga ako nagpaputok\n\n”);
printf(“nun \nbagong taon… \nbaket\n???”);
printf(“\nkasi\t sumasabog na ang \”puso ko\” sa’yo”);
\ di nga ako nagpaputok_ _
_
_nun_
_bagong taon… _
_baket_
_???_
_kasi_ _sumasabog na ang _“puso ko_“_sa’yo_
Tags