Interpreter doesnt work?

G

globalrev

so i downloaded and installed ruby and there is no APPlicatin/Exe int
he main directory but in bin there is the interpreter but ti doesnt
work, it aluches a DOS-window but there is no evaluator.


do i have to install an IDE to or how do i get an editor and the
interactive prompt?
 
D

Drew Olson

globalrev said:
do i have to install an IDE to or how do i get an editor and the
interactive prompt?

Welcome to ruby!

To use the interactive prompt, also known as irb, open a console window
and type "irb" then hit enter.

You can also use any editor you like. I believe the one click installers
comes with a nice simple editor called SciTE which will give you syntax
highlighting. Once you've written your program, navigate to it using a
console window and then type "ruby my_program.rb" to execute your code.

Hope this helps.

- Drew
 
P

Peter Jones

globalrev said:
so i downloaded and installed ruby and there is no APPlicatin/Exe int
he main directory but in bin there is the interpreter but ti doesnt
work, it aluches a DOS-window but there is no evaluator.

You probably don't want to invoke the interpreter directly, but
instead send ruby source files through the interpreter to be executed.

First write some ruby code in your editor of choice, and then run that
code through the interpreter.

You can access an interactive session with the interpreter by opening
a DOS window and running the following command:

irb
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,291
Messages
2,571,455
Members
48,132
Latest member
KatlynC08

Latest Threads

Top