Skip to content
Sign upLog in
← Back to Community
can i use irb? how can i use it?
Profile icon
TingziZhang

require 'open-uri'
open('https://www.nytimes.com')

i try to open this url. but nothing happens. only errors

Voters
Profile icon
YasminFarley
Profile icon
TingziZhang
Comments
hotnewtop
Profile icon
SixBeeps

Works for me?
image

Profile icon
TingziZhang

im new to this. so it might sound silly. when i run from the file. it doesnt show. but if i run directlhy from the command window then it works
image

Profile icon
SixBeeps

@TingziZhang
Ah, the thing on top is for writing Ruby files. If you want to use IRB, you'll have to use the console window.

Profile icon
SixBeeps

@TingziZhang
irb is a console app

Profile icon
TingziZhang

@SixBeeps
i see. i thought using this would make it easier than directly from ruby installer. thanks!! any suggestions on an easier platform to use tho?

Profile icon
SixBeeps

Nah, I don't use Ruby very much.