import flask
import time
import os
import sys
import subprocess
#app = flask.Flask(__name__)
#@app.route('/')
#def index():
#	def inner():
#		proc = subprocess.Popen(['python','shitty.py'],shell=True,stdout=subprocess.PIPE)
#		for line in iter(proc.stdout.readline,''):
#			time.sleep(1)
#			yield line.rstrip()+ '<br/>\n'
#	return flask.Response(inner(),mimetype='text/html')
#app.run(debug=True,port=5000,host='0.0.0.0')

while(1):
	x = raw_input('Please input the choices for ret2win?\n')
	file = r'./solution.txt'
	y = "file ret2win"
	with open (file,'w') as filex:

		filex.write('{}\n'.format(y))
		filex.write('{}\n'.format(x))
	os.system('gdb -x solution.txt')
	print "You are out of debugger re-run"
