# Several units of the System, Help!

**URL:** <https://www.ruby-forum.com/t/several-units-of-the-system-help/155427>\
**Category:** Ruby\
**Created:** [December 11, 2008, 6:19pm UTC](https://www.ruby-forum.com/t/several-units-of-the-system-help/155427 "2008-12-11T18:19:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![darkskull](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b487fb/32.png) [@darkskull](https://www.ruby-forum.com/u/darkskull)\
**Post date:** [December 11, 2008, 6:19pm UTC](https://www.ruby-forum.com/t/several-units-of-the-system-help/155427/1 "2008-12-11T18:19:36Z")

</div>

Hi, I have a little doubt with a code that I’m doing, and that is what I  
need is to open a file with “File”, with the exact route, but saying  
that I look at all the units of the system, or the ‘A’ to ‘Z’. How could  
I do?, Here you get the code.

require ‘ftools’  
ip=ARGV[0]  
dns=ARGV[1]  
if !ARGV[0] or !ARGV[1]  
puts “Example use =\> “./phar 72.14.221.104 google.es””  
end  
host=File.open(‘C:/Windows/System32/drivers/etc/hosts’ , ‘a+’)  
host.print("#{ip}\s\s\s\s", “#{dns}\n”)

This is: " …===\> C: \<===/Windows/System32/… "
