Lee V. wrote in post #1090674:
Thank you! I downloaded Intype and everything makes sense now. I can
write multi line programs, save them, and view the result in ruby now!
Well, there's a little problem, actually. When I go to open the file,
the ruby screen will appear for a fraction of a second and then close.
It did this for 3 out of the 4 programs I saved. Is this a glitch that
has an easy fix?
Is not a trouble, see.. most of the programms will run and shut it down
by themself, that's why you see a window popping up and closing
instantly. If you want to see some prints or any result you have to
sleep the programm, from time to time, to see what's happening, like
this
puts "Hello there.."
sleep(3)
puts "How are you?.."
sleep(2)
puts "Sorry I'm bussy! Goodbye!"
sleep(1)
..sleep is a method, don't be afraid to use the documentation. Other
way is execute it from the console, what you want to do 99% of the time,
I've told you that before. WindowsKey + R, type "cmd", press Enter,
there you have to put:
ruby 'C:/RubyPrograms/MyFirstProgram/source_code.rb'
..play with that. You're next step is to be familiarized with cmd, will
help you a lot. Instead of put the full path you can do this in cmd
pwd
#=>C:\Users\You
cd ../
#=>C:\Users
cd ../
#=>C:
cd RubyPrograms
#=>C:\RubyPrograms
cd MyFirstProgram
#=>C:\RubyPrograms\MyFirstProgram
ruby source_code.rb
..the effect is the same that if you put the full path, you'll be more
confortably in the last way with time...
By the way, if you don't mind me asking, what is your
job title? I want to learn programming so I can get a job in it, but
aside from a job with the word programmer in the title, I don't know
what kind of jobs are out there. Basically, what can I do with this for
a job?
Good question, my title is: none. You don't need a word for the
beautifull things you can create, you don't need a paper to be a good
programmer, nobody can say that you are a bad programmer if you make
complex and big programms and if you know that you are. I'm a starter
like you, just with a year more of studies than you, I've read Pine's
book too. I've beeing in RubyConf of my country this year, there I meet
very smart and nice people, you can learn a lot from those places. I
work alone, this days I'm making my first payed programm to an
enterprise, where I work too that has nothing to do with programming,
I've presented a proyect to bring order to the enterprise, that today is
a messy, so its like an especific programm. That is a way: work alone;
the other is in a software development enterprise like Neo, haha! look
that's a good comparison, first way you'll be a nocturnal Neo ^^,
sencond way you'll be a morning Neo with good jackets and all those
stuff lol ^^. Seriously, I don't know how it is working for a boss in
programming, meaby another has to respond that.
···
--
Posted via http://www.ruby-forum.com/\.