Advertisement
Guest User

Untitled

a guest
Oct 25th, 2017
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
COBOL 0.99 KB | None | 0 0
  1. program-id. Program1 as "ConsoleApplication6.Program1".
  2.  
  3.        data division.
  4.        working-storage section.
  5.        01 degree pic zzz.99.
  6.        01 faran pic zzz.99.
  7.        01 operation pic 999 value 0.
  8.        
  9.        Screen section.
  10.        01 myScreen.
  11.            05 BlankScreen
  12.                foreground-color 2
  13.                background-color 6.
  14.                
  15.          05 line 1 col 1 value "Conversion table".
  16.          05 line 2 col 1 value " Degree     Fahrenheit".
  17.        
  18.  
  19.        procedure division.
  20.  
  21.        100main.
  22.        Display myScreen
  23.        Display ""
  24.        Display ""
  25.        
  26.        perform until operation > 150
  27.        perform 200getConv
  28.        
  29.        display degree "       "faran
  30.        add 10 to operation
  31.        
  32.        end-perform.
  33.        
  34.        
  35.        
  36.            stop run.
  37.            
  38.        200getConv.
  39.        compute faran rounded = ((9/5)*operation) + 32.
  40.        move operation to degree.
  41.        
  42.            
  43.        end program Program1.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement