Site pages
Current course
Participants
General
Topic 1
Topic 2
Topic 3
Topic 4
Topic 5
Topic 6
Topic 7
Topic 8
Topic 9
Topic 10
Topic 11
Topic 12
Topic 13
Topic 14
Topic 15
Topic 16
Topic 17
Topic 18
Topic 19
Topic 20
Topic 21
Topic 22
Topic 23
Topic 24
Topic 25
Topic 26
Topic 27
Topic 28
Topic 29
Topic 30
Topic 31
Topic 32
Topic 33
Topic 34
Topic 35
The PRINT statement
This statement writes the results of computations performed by the computer on the printer. The form of the PRINT statement is list --- may be constants, variables, expressions or message separated by commas or semicolons eg : 90 PRINT A, B, C This will print the value stored in A, B and C 92 PRINT “PRITAM” This will print the word PRITAM. 94 PRINT “ P =”,P Outputs the value of variable P which is preceded by the name of the variable, that is, first will be printed P= and then the value of P. 96 PRINT 6 +7*2, A the value of expression 6+7*2 is calculated first. It is 20. Then 20 and the value of ‘A’ are printed, in that order, on the same line. 98 PRINT When this statement is executed, a line is skipped on the printer. Thus, this form of PRINT statement is useful to insert spaces in the output data. |
Last modified: Wednesday, 18 January 2012, 11:07 PM