Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- =begin
- The following block of code belongs to a program that is under construction currently
- =end
- print "File name: "
- filename = gets.chomp
- if File.readable?("#{filename}")
- File.open("#{filename}", "r") do |f|
- f.each_line do |line|
- puts line
- end
- end
- else puts "The given file '#{filename}' is not readable."
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement