Skip to content

batuhanbatu/hello-world-cobol

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

A Simple Hello World Program in COBOL by Batuhan Batu

Hi, in this article, I will let you know about how to create a "Hello World" program with COBOL.

First of all, your computer needs to have this repository and a cobol compiler (may also be online compiler).

After you have this two, you will be able to run the program. If you want to run the program in your terminal, I explained you about the details of the steps belove.

1- The first step here we will do is to open our working directory from the terminal by "cd Directory/Directory" command. In my computer, I put my files into Downloads/cobol/hello-world-cobol" directory.

N|Solid

2- After opening your directory, we will create an executable file from our cob file, which should be written as "cobc -x hello-world.cob" (hello-world.cob part may be changed according to your file name)

N|Solid

3- Then, we are writing running command to our terminal which is "./filename", In my computer since I named my file as "hello-world", I wrote "./hello-world"

N|Solid

4- Here you will see the result of your program

N|Solid

You may want to know that we can run the same program by doing the last step but if we changed something in our program, we should make an executable file again (which points 2nd step I mentioned)

Thank you so much for reading till here, Hope to see you on next projects.. Batuhan Batu

Releases

No releases published

Packages

No packages published

Languages