LoginSignup
8
8

More than 5 years have passed since last update.

[Ruby] ユーザに Y/n を1行で求める

Posted at
y_or_n.rb
require 'highline/import'
p 'yes' if HighLine.agree('Do it? [Y/n]')

require含め2行か

参考

https://gist.github.com/botimer/2891186
http://www.rubydoc.info/gems/highline/1.6.21/HighLine:agree

8
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8
8