How to write a simple program: "Hello World"

in #introduceyourself6 years ago (edited)

Hello World

Hello world is a small, simple program that is used to demonstrate the syntax of a programming language.


If you read my last post, I recommended ruby. That will be the programming language we'll be using to write our simple program. You can download ruby here for any platform:

The Program

Here is the entire “Hello World” program written in ruby:

puts “Hello World”

If you saved that snippet as hello_world.rb (a ruby file), and ran it in your terminal(or command prompt on windows), it would look like this:

ruby hello_world.rb
Hello World

the first line in the above snippet is running the program hello_world.rb, and the second line is the output from the program, in this case, it is printing Hello World.


I made a gif showing me writing this program from the start, I’m using vim as the text editor to write the ruby file, save it, then run it with the same commands I used above:

That’s it! First Program Written. We're all programmers now.

A bit about me

I've been learning about programming for at least a decade, and I probably won't stop. You can check out my intro post and some of the projects I've worked on:

And my last post "How to become a self-taught programmer":


Spacemacs better than vim. Everyone knows this.

Nice post though

What was the best part of your weekend?

Welcome to Steemit! If you would like to see statistics of any post on Steemit, you can use I have made a bookmark for your convenience in accessing Steemd.

Boldness, without the rules of propriety, becomes insubordination.

Wow! Amazing post! I look forward to reading more.

Coin Marketplace

STEEM 0.23
TRX 0.07
JST 0.030
BTC 20358.95
ETH 1152.46
USDT 1.00
SBD 3.20