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
4
votes
0 answers

Link input to an output in React

I'm new to React and I'd try to tinker a little bit with dataflow when using and some kind of output. The idea is to type something in an input bar and have it shown below the bar as the user is typing. I wish to do this without stuff like Flux or…
Lehren
  • 99
  • 2
  • 11
4
votes
6 answers

Is it possible to iterate through an array list with elements of different data types and put them out?

Without generics it is possible to create an ArrayList with elements of different types. I want to iterate through it and put out the elements. I can not use a for-each-loop, because it wants a specific type. I tried Iterator but wasn't…
a kind person
  • 329
  • 1
  • 6
  • 17
4
votes
2 answers

Write dynamical arrays in Fortran 90

I have arrays with dynamical dimension (dimx, dim) and I need a way to write such arrays in a file through the Write instruction, the problem is that until now I haven't been able to produce such files in a automatic way, I mean until now I have to…
mors
  • 53
  • 1
  • 5
4
votes
4 answers

System.in.read() behaviour i can't explain

class E92StringDemo { public static void main(String args[]) throws java.io.IOException { String strObj1 = "First String"; for (int i = 0; i < strObj1.length(); i++) { System.out.print(strObj1.charAt(i)); …
user3260381
4
votes
6 answers

Console two line output

I have this code which output some value from array, plus - in new line under value a[i] Console.Write(a[i] + "\n-"); So it looks like this a - Now i have more of Console.Write(a[i+1] + "\n-"); codes and it outputs like this a -b -c -d - I know…
gagro
  • 371
  • 7
  • 18
4
votes
1 answer

Can i generate the input given the output in a pretrained Tensorflow model?

Let's assume i have trained a model for the MNist task, given the following code: from tensorflow.examples.tutorials.mnist import input_data mnist = input_data.read_data_sets("/tmp/data/", one_hot=True) import tensorflow as tf #…
4
votes
3 answers

How to set a Textbox to allow multiple lines, and scrollability

I am returning multiple different sizes of strings into a box. I have used a System.Windows.Forms.Label but unfortunately some of the strings are too large for it, and do not display. I have tried replacing it with a System.Windows.Forms.TextBox but…
M24Kermit
  • 53
  • 1
  • 1
  • 4
4
votes
1 answer

tee output not appearing until cmd finishes

Usually if I want to print the output of a command and in addition capture that output in a file, tee is the solution. But I'm making a script using a utility which seems to have a special behaviour. It's the wps wireless assessment tool bully. If I…
OscarAkaElvis
  • 5,384
  • 4
  • 27
  • 51
4
votes
1 answer

C output too long

I have a question about my little c program: #include #include int main() { int c, len; int max = 100; char *buffer = malloc(max); for (len = 0; (c = getchar()) != EOF; len++) { buffer[len] = c; …
werther
  • 47
  • 7
4
votes
1 answer

Julia - Defining a function that outputs a function

I'm trying to create a small function to define the Hamiltonian flow if inputted the functions the Hamiltonian consists of. E.g. I would like to define function makeThedH(f::Function,g::Function) dH1(s,u) = cos(u[3]).*f(u[1],u[2]); dH2(s,u) =…
Aaron Chen
  • 43
  • 4
4
votes
2 answers

How to format a multi-line toString() using printf in Java

So for my beginners programming class we had to code a program focusing on inheritance where we could create and enter information for different kinds of college students. I have the program and the output working just fine, but my professor wants…
Abbey S
  • 111
  • 2
  • 15
4
votes
1 answer

Output of a fortran program into a variable

I have an interactive FORTRAN program that requires various inputs from the user. Now, I want to store the output of this Fortran program into a variable and use this value in a shell script. I tried var=`./test` and var=$(./test) but in both the…
4
votes
1 answer

write output to command prompt using java

I am trying to open a command prompt from a java class and send output to the new command prompt. I can open cmd using process. Gone through all the answers on SO,but couldn't figure out how can I pass the output to the just created cmd window.
Coded9
  • 159
  • 2
  • 14
4
votes
1 answer

MongoDB in Luigi Python

I would like to know if there is a way to output to a MongoDB in Luigi. I see in the documentation they support files (local FS, HDFS), S3, PostgreSQL but not MongoDB. If not, could someone explain me why not? Maybe it is a bad idea to have it? I…
user2288043
  • 241
  • 4
  • 15
4
votes
1 answer

Keeping the user's input intact when outputing to terminal at the same time

To simplify, let's say I'm trying to write a command line two-way chat in Python. I would like the user to input his message with input() at the command prompt, but a listening thread could print a message at any moment. By default, this would…
Juicy
  • 11,840
  • 35
  • 123
  • 212