Print lines of input along with output.
777959
def main():
    
    source_lines = (line.rstrip() for line in sys.stdin)
    console = InteractiveInterpreter()
    console.runsource('import turicreate')
    source = ''
    try:
        while True:
            source = source_lines.next()
            more = console.runsource(source)
            while more:
                next_line = source_lines.next()
                print '...', next_line
                source += '\n' + next_line
                more = console.runsource(source)
    except StopIteration:
        if more:
            print '... '
            more = console.runsource(source + '\n')
819548
def log(self, *lines):
        """"""
        if getattr(self, "debug", False):
            print(dt.datetime.now().time(), end=' ')
            for line in lines:
                print(line, end=' ')
            print()
1235024
def _input_as_lines(self,data):
        
        if data:
            self.Parameters['-infile']\
                .on(super(Clustalw,self)._input_as_lines(data))
        return ''
794539
def fout(self, output, newline=True):
        """"""
        if output is not None:
            self.out(self.fmt(output), newline=newline)
303928
def _output_to_list(cmdoutput):
    '''
    
    '''
    return [item for line in cmdoutput.splitlines() if _safe_output(line) for item in line.split()]
698857
def _println(self, *args):
        ''''''
        string = ' '.join([str(arg) for arg in args])
        print(string, file=self._stream)
1232653
def print_files(opts, file_paths):
    
    print("Parsing the following files:")
    for file_path in file_paths:
        print("  " + strip_prefix(file_path, opts.abs_input))
    print("--------------------")
    print(str(len(file_paths)) + " total\n")
700718
def main():
    
    buff = ''
    for line in fileinput.input():
        buff += line

    parser = jbossparser.JbossParser()
    result = parser.parse(buff)
    print(json.dumps(result))
511687
def output(stream):
    """"""
    while True:
        content = stream.read(1024)
        if len(content) == 0: break
        sys.stdout.write(content)
1057477
def output_capturing():
    """"""
    out = sys.stdout

    sys.stdout = StringIO()

    try:
        yield

    finally:
        sys.stdout = out
927751
def getOutputBlocks():
    """"""
    raw=open("output.txt").read()
    d={}
    for block in raw.split("\n####### ")[1:]:
        title=block.split("\n")[0].split("(")[0]
        block=block.split("\n",1)[1].strip()
        d[title]=block.split("\nfinished in ")[0]
    return d
1066652
def print(self, output_file=sys.stdout, log=False):
        """"""

        for soln in iter(self):
            print(soln, file=output_file)
            print(SOLN_SEP, file=output_file)

        if self.status == 0:
            print(SEARCH_COMPLETE, file=output_file)

        if (self.status == 1 and self._n_solns == 0) or self.status >= 2:
            print({
                Status.INCOMPLETE : ERROR,
                Status.UNKNOWN: UNKNOWN,
                Status.UNSATISFIABLE: UNSATISFIABLE,
                Status.UNBOUNDED: UNBOUNDED,
                Status.UNSATorUNBOUNDED: UNSATorUNBOUNDED,
                Status.ERROR: ERROR
            }[self.status], file=output_file)

            if self.stderr:
                print(self.stderr.strip(), file=sys.stderr)

        elif log:
            print(str(self.log), file=output_file)
853697
def print_info(self, buf=None):
        """"""
        buf = buf or sys.stdout
        print >> buf, "Sections:"
        for i, section in enumerate(self._sections):
            print >> buf, "  %s:\t%s (%s)" % (i + 1, section[0], section[1])
453467
def writelines(self, lines, level=0):
        """"""
        for line in lines:
            for line in line.rstrip(u'\n').split(u'\n'):
                self.write(line.rstrip(u'\n'), level=level)
110387
function print(str, indent, inline) {
        var lines = str.split('\n');

        for(var i=0; i<lines.length; i++) {
            if(lines[i]) {
                if((inline && i > 0) || !inline) {
                    for(var j=0; j<indent; j++) {
                        process.stdout.write(' ');
                    }
                }
            }

            if(i === lines.length-1) {
                process.stdout.write(lines[i]);
            }
            else {
                process.stdout.write(lines[i] + '\n');
            }
        }
    }
80560
def copy_all_lines_from_to(inputFile, outputFile):
    """"""
    currentLine = inputFile.readline()
    while currentLine:
        outputFile.write(currentLine)
        currentLine = inputFile.readline()
502359
def show_first_and_last_lines(result):
    """"""
    lines = [line for line in result.split('\n')]
    if len(lines) < 11:
        for line in lines:
            print(line)
        return
    print('Showing first few lines...')
    for line in lines[:5]:
        print(line)
    print('...')
    print('Showing last few lines...')
    for line in lines[-5:]:
        print(line)