title: Python split, replace
body: <p>I am writing a scrip and have run into a roadblock.  There is probably a more efficient way to do this, but I am fairly new to Python.  I am trying to create a list of user generated IP addresses.  I am using print to see if the produced values are correct.  When I run this code, the print ip_start has the same value and is not updated.  I am sure this is a fairly simple fix but I have a major brain lock.</p>
  
  <pre><code>ip_start = raw_input('Please provide the starting IP address for your scan --&gt; ')
  start_list = ip_start.split(".")
  ip_end = raw_input('Please provide the ending IP address for your scan --&gt; ')
  end_list = ip_end.split(".")
  top = int(start_list[3])
  bot = int(end_list[3])
  octet_range = range(top,bot)
  print octet_range
  for i in octet_range:
      print i
      print "This the top:" + str(top)
      ip_start.replace(str(top),str(i))
      print ip_start
  </code></pre>