Questions tagged [output]

The externally observable consequences of calling a program on some input

The output of a program is the set of externally observable consequences of running a program on the given input.

A program's output can be manifested in several forms:

  1. What is printed to and/or
  2. What is written to an external file
  3. What changes are made to the inputs, which are then used in other functions or programs
9797 questions
7
votes
1 answer

How to write console output on text file

I am new to programming and I've searched the webpage for the answer to this question and have tried many possibilities without success. I have currently managed to connect a potentiometer to my raspberry and get values on the console, but I don't…
Dani DcTurner
  • 73
  • 1
  • 1
  • 5
7
votes
1 answer

Suppress Messages from zip in R

I want to suppress the messages as outputted by the zip command in r but I fail to find the right command to do so. Background, as I use the zip-function within a function, I don't want the user to see all information about all the files (roughly…
David
  • 9,216
  • 4
  • 45
  • 78
7
votes
1 answer

REST Streaming JSON Output

We have JAX RS implementation which needs to send back JSON output. But the response size is huge. And the client expects the same synchronously. Hence I tried to use StreamingOutput... but the client is not really getting the data in chunks. Below…
Soumen Ghosh
  • 168
  • 2
  • 11
7
votes
1 answer

Log to file with gradle 4

Until gradle 3, I used this to write gradle's output to a logfile: def fileLogger = [ onOutput : { File logfile = new File( 'gradle.log' ) logfile << it } ] as org.gradle.api.logging.StandardOutputListener gradle.useLogger(…
elsamuko
  • 668
  • 6
  • 16
7
votes
3 answers

Python capture subprocess output after termination

I am trying to get subprocess output (on Windows) at the time the TimeoutExpired exception is raised. Any ideas? try: proc = subprocess.run(cmd,timeout=3) except subprocess.TimeoutExpired: print(???)
Ali_G
  • 71
  • 1
  • 3
7
votes
3 answers

U-SQL Output in Azure Data Lake

Would it be possible to automatically split a table into several files based on column values if I don't know how many different key values the table contains? Is it possible to put the key value into the filename?
peterko
  • 503
  • 1
  • 6
  • 18
7
votes
1 answer

Output of Tensorflow LSTM-Cell

I've got a question on Tensorflow LSTM-Implementation. There are currently several implementations in TF, but I use: cell = tf.contrib.rnn.BasicLSTMCell(n_units) where n_units is the amount of 'parallel' LSTM-Cells. Then to get my output I call: …
LJKS
  • 899
  • 2
  • 9
  • 17
7
votes
2 answers

How to get rid of new line characters in an output of Node.js util.inspect?

An issue with Node.js' util.inspect function. I use it to colorize Node.js console output and to format objects. All works fine except that util.inspect prints all those \r\n characters too. The example. Given a file: //…
Green
  • 28,742
  • 61
  • 158
  • 247
7
votes
1 answer

Best way to determine if a function has an output?

I have a list of functions that runs a fairly deep routine to determine which post_id to get its content from and output it on the site's frontend. When this function returns its content I want it to be wrapped in an html wrapper. I want this html…
Fearless Mode
  • 241
  • 3
  • 13
7
votes
5 answers

Java : Issue with capturing execution time per iteration in a Map

I've a requirement to capture the execution time of some code in iterations. I've decided to use a Map for capturing this data where Integer(key) is the iteration number and Long(value) is the time consumed by that iteration in…
user6077173
7
votes
3 answers

Output to two different consoles using python

I am writing a script and I have two different kinds of output, say Op1 and Op2. I want to output Op1 to the terminal where the python process was called from while Op2 should be dumped to a different terminal instance. Can I do that? Even if the…
axolotl
  • 1,042
  • 1
  • 12
  • 23
7
votes
3 answers

Postgresql output EXPLAIN ANALYZE to file

I need to know how long a particular query will run (I'm expecting a very long run time). To do this, I've decided to run an EXPLAIN ANALYZE on the query set with only a piece of the entire dataset and extrapolate from there. But I have a problem;…
Thomas
  • 871
  • 2
  • 8
  • 21
7
votes
3 answers

Formatting output with printf: truncating or padding

I would like to produce the following output: > Avril Stewart 99 54 > Sally Kinghorn 170 60 > John Young 195 120 > Yutte Schim... 250 40 As you can see, names shorter than 14 characters are padded with spaces. Names longer than 15 characters…
Dave Smith
  • 97
  • 1
  • 2
  • 6
7
votes
3 answers

What does an integer that has zero in front of it mean and how can I print it?

class test{ public static void main(String args[]){ int a = 011; System.out.println(a); } } Why I am getting 9 as output instead of 011? How can I get 011 as output?
Dhanuka Perera
  • 1,395
  • 3
  • 19
  • 29
7
votes
1 answer

How to specify download location in Html using JavaScript

is it possible to specify the download location for a file from a Html page using JavaScript? the function I am currently using to down my file is provided below. function saveTextAsFile() { var textToWrite =…
Niall_Maher
  • 171
  • 2
  • 3
  • 11